X-Original-To: pgsql-odbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 6889A9DCA0A for ; Wed, 21 Dec 2005 03:27:29 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 88127-09 for ; Wed, 21 Dec 2005 03:27:29 -0400 (AST) Received: from pgfoundry.org (pgfoundry.org [200.46.204.130]) by postgresql.org (Postfix) with ESMTP id 820A29DCA2F for ; Wed, 21 Dec 2005 03:27:27 -0400 (AST) Received: from localhost (av.hub.org [200.46.204.144]) by pgfoundry.org (Postfix) with ESMTP id 095131125073; Wed, 21 Dec 2005 07:27:28 +0000 (GMT) Received: from pgfoundry.org ([200.46.204.130]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 94547-08; Wed, 21 Dec 2005 03:27:26 -0400 (AST) Received: by pgfoundry.org (Postfix, from userid 80) id 393F91125038; Wed, 21 Dec 2005 07:27:26 +0000 (GMT) To: noreply@pgfoundry.org From: Subject: =?UTF-8?Q?[_psqlodbc-Bugs-1000495_]_duplicate_key_causes_HY000_SQL-State?= Content-type: text/plain; charset=UTF-8 Message-Id: <20051221072726.393F91125038@pgfoundry.org> Date: Wed, 21 Dec 2005 07:27:26 +0000 (GMT) X-Virus-Scanned: by amavisd-new at hub.org X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=-0.842 required=5 tests=[ALL_TRUSTED=-1.44, AWL=0.048, NO_REAL_NAME=0.55, SUBJECT_EXCESS_QP=0] X-Spam-Score: -0.842 X-Spam-Level: X-Archive-Number: 200512/275 X-Sequence-Number: 6754 Bugs item #1000495, was opened at 2005-12-21 07:27 You can respond by visiting: http://pgfoundry.org/tracker/?func=detail&atid=538&aid=1000495&group_id=1000125 Category: None Group: None Status: Open Resolution: None Priority: 3 Submitted By: Tom Zschockelt (toz) Assigned to: Nobody (None) Summary: duplicate key causes HY000 SQL-State Initial Comment: while inserting a row into an table with primary key the current snapshot ( 8.01.01.05 ) returns a wrong sqlstate HY000 instead of the 8.01.01.02 driver which returns a 23005 sqlstate (which is correct) e.g. create table test1 ( field1 int2 primary key, field2 varchar(10) null ); insert into test1 (field1, field2) values ( 1, 'test'); insert into test1 (field1, field2) values ( 1, 'another test'); AFAIK the second insert should return with SQL_ERROR and sqlstate 23000 or 23005. ---------------------------------------------------------------------- You can respond by visiting: http://pgfoundry.org/tracker/?func=detail&atid=538&aid=1000495&group_id=1000125