By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,692 Members | 1,998 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,692 IT Pros & Developers. It's quick & easy.

ERROR: column "id" does not exist

P: n/a
Hy

i have a problem with the following statement:

SELECT MAX(id) FROM apconfig;

if i send this statement i got the following error:

ERROR: column "id" does not exist

Can anyone explain me this error? There is the column id, and there are
also entries in it.

thx

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to ma*******@postgresql.org)

Nov 23 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
On Mon, Nov 15, 2004 at 01:44:47PM +0100, Sandro Daehler wrote:
SELECT MAX(id) FROM apconfig;

if i send this statement i got the following error:

ERROR: column "id" does not exist

Can anyone explain me this error? There is the column id, and there are
also entries in it.


The column might have a different case or possibly leading or
trailing spaces, in which case you'll have to quote it verbatim.
What does \d apconfig show? If that doesn't show the problem
then try this:

SELECT quote_ident(attname) FROM pg_attribute
WHERE attrelid = 'apconfig'::regclass;

--
Michael Fuhr
http://www.fuhr.org/~mfuhr/

---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

Nov 23 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.