dbTalk Databases Forums  

Re: [BUGS] BUG #1570: Double quotes in all field/table names must be

mailing.database.pgsql-bugs mailing.database.pgsql-bugs


Discuss Re: [BUGS] BUG #1570: Double quotes in all field/table names must be in the mailing.database.pgsql-bugs forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Bruce Momjian
 
Posts: n/a

Default Re: [BUGS] BUG #1570: Double quotes in all field/table names must be - 04-02-2005 , 08:21 PM






Christopher Brian Jurado wrote:
Quote:
The following bug has been logged online:

Bug reference: 1570
Logged by: Christopher Brian Jurado
Email address: cbjurado (AT) yahoo (DOT) com
PostgreSQL version: 8.0
Operating system: Windows 2000
Description: Double quotes in all field/table names must be optional!
Details:

The double quote(") for field/table names doesn't seem to be optional when
using it in queries.

I used pgAdmin under verion 8.0 to query any field on any table. A message
says the relation does not exist. If I double-quote the field names and
table names, then it works. Isn't it a very big burden to keep typing double
quotes?

I tried searching through the postgresql.conf file but nothing is there to
control this behavior.

In the documentation, they show samples without double quotes but it
actually doesn't work when you try it.
The problem is that when you create a mixed upper/lowercase table or
column name using pgadmin, it double-quotes the identifier in CREATE,
but when you access it via SQL, you need to double-quote it yourself.

I think this is done because it allows pgadmin to preserve any case used
in the create, and pgadmin is consistent in quoting, but when you access
via SQL, you have to then do it too.

I think the only solution is to use only lowercase when creating objects
in pgadmin, unless you want to do double-quoting.

--
Bruce Momjian | http://candle.pha.pa.us
pgman (AT) candle (DOT) pha.pa.us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

---------------------------(end of broadcast)---------------------------
TIP 9: the planner will ignore your desire to choose an index scan if your
joining column's datatypes do not match


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.