Re: [SQL] update syntax

2005-06-15 Thread Bruno Wolff III
On Wed, Jun 15, 2005 at 14:35:42 +0200, Praveen Raja <[EMAIL PROTECTED]> wrote: > Thanks. The UPDATE works ok now. But using the same logic it doesn’t > seem possible to delete rows. Is this also possible? Yes. When you use table names in the where clause they are automatically added to the join

Re: [SQL] update syntax

2005-06-15 Thread Bruno Prévost
AND b.col3 = ‘somethingelse’)   - Original Message - From: Praveen Raja To: 'Bruno Prévost' Cc: pgsql-sql@postgresql.org Sent: Wednesday, June 15, 2005 8:35 AM Subject: RE: [SQL] update syntax Thanks. The UPDATE works ok now. But using the same l

Re: [SQL] update syntax

2005-06-15 Thread Praveen Raja
: [SQL] update syntax   Try something like this   UPDATE table1 SET col1 = b.col1 FROM table1 b WHERE table1.col2 = b.col2 and table1.col3 = ‘something’ and b.col3 = ‘somethingelse’   - Original Message - From: Praveen Raja To: pgsql-sql@postgresql.org

Re: [SQL] update syntax

2005-06-15 Thread Bruno Prévost
Try something like this   UPDATE table1SET col1 = b.col1FROM table1 bWHERE table1.col2 = b.col2 andtable1.col3 = ‘something’ andb.col3 = ‘somethingelse’   - Original Message - From: Praveen Raja To: pgsql-sql@postgresql.org Sent: Wednesday, June 15, 2005 7:39 AM Subje

Re: [SQL] update syntax error?

2000-08-21 Thread mikeo
query should have a comma instead of the word and... HTH mikeo At 04:27 PM 8/20/00 -0300, The Hermit Hacker wrote: > >UPDATE SET field1=,field2= > >On Tue, 15 Aug 2000, k.c. hemelstrand wrote: > >> Can anybody help with why I am receiving the error below? >> >> Thanks >> K.C. >> >> >> parts=

Re: [SQL] update syntax error?

2000-08-20 Thread The Hermit Hacker
UPDATE SET field1=,field2= On Tue, 15 Aug 2000, k.c. hemelstrand wrote: > Can anybody help with why I am receiving the error below? > > Thanks > K.C. > > > parts=# \d av_parts > Table "av_parts" > Attribute |Type |