BUG #1581: Problem with capitalised DB names...

Started by Marcus v. Scottiabout 21 years ago5 messagesbugs
Jump to latest
#1Marcus v. Scotti
m.scotti@fry-it.com

The following bug has been logged online:

Bug reference: 1581
Logged by: Marcus v. Scotti
Email address: m.scotti@fry-it.com
PostgreSQL version: 7.4.7
Operating system: Linux
Description: Problem with capitalised DB names...
Details:

When trying to grant database privileges to a group of users there is no way
to do this if the database name is capitalised (i.e. db-name = Test). The
error message when performing the grant operation:

grant all on DATABASE test to group tgroup;

is:

ERROR: database "test" does not exist

I have used capitalisation an a number of databases, so this now seems to
require me to rename them all in to lower-case...

#2Bruno Wolff III
bruno@wolff.to
In reply to: Marcus v. Scotti (#1)
Re: BUG #1581: Problem with capitalised DB names...

On Tue, Apr 05, 2005 at 18:09:25 +0100,
"Marcus v. Scotti" <m.scotti@fry-it.com> wrote:

Description: Problem with capitalised DB names...
Details:

When trying to grant database privileges to a group of users there is no way
to do this if the database name is capitalised (i.e. db-name = Test). The
error message when performing the grant operation:

grant all on DATABASE test to group tgroup;

is:

ERROR: database "test" does not exist

I have used capitalisation an a number of databases, so this now seems to
require me to rename them all in to lower-case...

You need to use double quotes (") around database, table or column names that
are not all lowercase.

#3Marcus v. Scotti
mvscotti@gmail.com
In reply to: Bruno Wolff III (#2)
Re: BUG #1581: Problem with capitalised DB names...

Hi Bruno,

Thanks... (maybe include this in the manuals, I couldn't find this
information...)

Best Regards
Marcus

On Apr 10, 2005 11:23 PM, Bruno Wolff III <bruno@wolff.to> wrote:

On Tue, Apr 05, 2005 at 18:09:25 +0100,
"Marcus v. Scotti" <m.scotti@fry-it.com> wrote:

Description: Problem with capitalised DB names...
Details:

When trying to grant database privileges to a group of users there is no way
to do this if the database name is capitalised (i.e. db-name = Test). The
error message when performing the grant operation:

grant all on DATABASE test to group tgroup;

is:

ERROR: database "test" does not exist

I have used capitalisation an a number of databases, so this now seems to
require me to rename them all in to lower-case...

You need to use double quotes (") around database, table or column names that
are not all lowercase.

--
Marcus v. Scotti
Director
Fry-IT LTD

www.fry-it.com

#4Bruno Wolff III
bruno@wolff.to
In reply to: Marcus v. Scotti (#3)
Re: BUG #1581: Problem with capitalised DB names...

On Mon, Apr 11, 2005 at 09:37:08 +0100,
"Marcus v. Scotti" <mvscotti@gmail.com> wrote:

Thanks... (maybe include this in the manuals, I couldn't find this
information...)

It is:
http://developer.postgresql.org/docs/postgres/sql-syntax.html#SQL-SYNTAX-IDENTIFIERS

#5Marcus v. Scotti
mvscotti@gmail.com
In reply to: Bruno Wolff III (#4)
Re: BUG #1581: Problem with capitalised DB names...

Hi Bruno,

Oops, I've overlooked that passage. Thanks for your help and sorry for
wasting your time.

Best Ragards
Marcus

On Apr 11, 2005 6:18 PM, Bruno Wolff III <bruno@wolff.to> wrote:

On Mon, Apr 11, 2005 at 09:37:08 +0100,
"Marcus v. Scotti" <mvscotti@gmail.com> wrote:

Thanks... (maybe include this in the manuals, I couldn't find this
information...)

It is:
http://developer.postgresql.org/docs/postgres/sql-syntax.html#SQL-SYNTAX-IDENTIFIERS

--
Marcus v. Scotti
Director
Fry-IT LTD

www.fry-it.com