X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.224.130]) by svr1.postgresql.org (Postfix) with ESMTP id 470F4D1CC78 for ; Fri, 3 Oct 2003 19:51:18 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (neptune.hub.org [64.117.224.130]) (amavisd-new, port 10024) with ESMTP id 27011-06 for ; Fri, 3 Oct 2003 16:50:29 -0300 (ADT) Received: from wolff.to (wolff.to [66.93.249.74]) by svr1.postgresql.org (Postfix) with SMTP id E8EB6D1B52E for ; Fri, 3 Oct 2003 16:39:56 -0300 (ADT) Received: (qmail 23165 invoked by uid 500); 3 Oct 2003 19:47:16 -0000 Date: Fri, 3 Oct 2003 14:47:16 -0500 From: Bruno Wolff III To: "John B. Scalia" Cc: pgsql-sql@postgresql.org Subject: Re: Bug in psql - Postgresql 7.3.1? Message-ID: <20031003194716.GB23110@wolff.to> Mail-Followup-To: "John B. Scalia" , pgsql-sql@postgresql.org References: <001a01c389b0$e00773a0$2501a8c0@John> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <001a01c389b0$e00773a0$2501a8c0@John> User-Agent: Mutt/1.5.4i X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200310/55 X-Sequence-Number: 15455 On Fri, Oct 03, 2003 at 09:18:44 -0400, "John B. Scalia" wrote: > All, > > > > I'm not certain if what I'm trying to do is legal, but if I execute a > statement like: > > > > UPDATE my_table SET field1='new_value' AND SET field2='different_value' > WHERE my_table_id = 'key'; It should be: UPDATE my_table SET field1='new_value', field2='different_value' WHERE my_table_id = 'key'; > in psql, it reports that it has successfully updated one record. I am not sure why you aren't getting a syntax error. > However, the record does not appear to be updated when I subsequently > issue a SELECT for that record. I'll buy the fact that I may be using > illegal syntax - I'm not SQL expert, but the update says it worked when > in fact it did not. Should this have worked or should it have reported > an error?