From: | Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com> |
---|---|
To: | "Reuben D(dot) Budiardja" <techlist(at)voyager(dot)phys(dot)utk(dot)edu> |
Cc: | <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: Error with word 'desc' |
Date: | 2003-06-24 14:52:07 |
Message-ID: | 20030624074956.S4481-100000@megazone23.bigpanda.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Tue, 24 Jun 2003, Reuben D. Budiardja wrote:
> Hi,
> Seems that everytime I use the word 'desc' I got an error. For example, this
> query:
> SELECT code, desc FROM or_code_table WHERE tr = 'FORMAT'
> gave me
> ERROR: parser: parse error at or near "desc"
>
> When I created the table I got the same error too. I got around that by
> creating the table using pgaccess instead of using psql console.
>
> Is 'desc' a reserved key word of some kind ? Even if yes (like in mysql or
> oracle), the parser should understand the context in which it's mentioned. I
> don't remember I got that kind of error with mysql / oracle.
Desc is a reserved word. You'll need to double quote it ("desc") in the
query for it to be legal.
From | Date | Subject | |
---|---|---|---|
Next Message | Tim Hawkins | 2003-06-24 14:54:47 | Re: [GENERAL] Documentation quality WAS: interesting |
Previous Message | Tom Lane | 2003-06-24 14:51:09 | Re: Many Pl/PgSQL parameters -> AllocSetAlloc(128)? |