Re: [GENERAL] very odd behavior

2001-05-10 Thread newsreader

Thanks everyone for very quick reply.

The reason I found odd was I had
created another able with the same
field name and don't recall having
problems at the time with 7.0.3.
Or did I get the same problem
but I just forgot?  I dumped
and reloaded 7.0.3 table to 7.1
without problem though.

On Thu, May 10, 2001 at 12:26:53PM -0600, Creager, Robert S wrote:
 
 desc is a keyword - ORDER BY DESC-ending
 
 Robert Creager
 StorageTek
 INFORMATION made POWERFUL
 
  -Original Message-
  From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
  
  I have 7.1
  
  Can someone take a look the following
  and tell me why I'm getting errors?
  I'm completely baffled!
  
  
  what= create table bla(desc text,def text,data text);
  ERROR:  parser: parse error at or near desc
  what= create table bla(desc text,def text,data text);
  CREATE
  what=

---(end of broadcast)---
TIP 6: Have you searched our list archives?

http://www.postgresql.org/search.mpl



Re: [GENERAL] very odd behavior

2001-05-10 Thread Jeff Daugherty

desc is a reserved word (descending, ascending, having,  from, etc...),
as in:
select * from foo order by col_a desc;
That is why you need the double quotes.
jeff



Jeff Daugherty
Database Systems Engineer
Great Bridge LLC

[EMAIL PROTECTED] wrote:

 I have 7.1
 
 Can someone take a look the following
 and tell me why I'm getting errors?
 I'm completely baffled!
 
 
 what= create table bla(desc text,def text,data text);
 ERROR:  parser: parse error at or near desc
 what= create table bla(desc text,def text,data text);
 CREATE
 what=
 
 ---(end of broadcast)---
 TIP 2: you can get off all lists at once with the unregister command
 (send unregister YourEmailAddressHere to [EMAIL PROTECTED])


---(end of broadcast)---
TIP 6: Have you searched our list archives?

http://www.postgresql.org/search.mpl



RE: [GENERAL] very odd behavior

2001-05-10 Thread Creager, Robert S


desc is a keyword - ORDER BY DESC-ending

Robert Creager
StorageTek
INFORMATION made POWERFUL

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
 
 I have 7.1
 
 Can someone take a look the following
 and tell me why I'm getting errors?
 I'm completely baffled!
 
 
 what= create table bla(desc text,def text,data text);
 ERROR:  parser: parse error at or near desc
 what= create table bla(desc text,def text,data text);
 CREATE
 what=

---(end of broadcast)---
TIP 6: Have you searched our list archives?

http://www.postgresql.org/search.mpl



Re: [GENERAL] very odd behavior

2001-05-10 Thread Patrick Welche

On Thu, May 10, 2001 at 02:08:56PM -0400, [EMAIL PROTECTED] wrote:
 I have 7.1
 
 Can someone take a look the following
 and tell me why I'm getting errors?
 I'm completely baffled!
 
 
 what= create table bla(desc text,def text,data text);
 ERROR:  parser: parse error at or near desc
 what= create table bla(desc text,def text,data text);
 CREATE
 what=

desc is used to mean descending, as in order by foo desc. If you enclose
that keyword in quotes, then the parser knows you are using it as a field
name and doesn't wonder about what should be descending..

Cheers,

Patrick

---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send unregister YourEmailAddressHere to [EMAIL PROTECTED])