delete fails due to referential integrity, but return code is 0. - Mailing list pgsql-bugs

From Leonid Furman
Subject delete fails due to referential integrity, but return code is 0.
Date
Msg-id DB3EDF713892D31191960008C7B11661827C1B@camxch01.cam.veritas.com
Whole thread Raw
List pgsql-bugs
Hello,

I am using PostgreSql on Windows NT 4.0 service pack 5.
PostgreSQL version is  PostgreSQL 7.0.0 on i686-pc-cygwin, compiled by gcc
egcs-2.91.57.
The client is an ODBC program which connects to the backend using odbc
driver version 6.50.00.00.

When deleting a record from table A referenced in table B: "delete from A
where id = 1001" using SQLExectDirect() the call returns 0 (this is wrong),
while the record is not deleted from table A (this is right)

Executing the same SQL statement from psql returns:

ERROR:  <unnamed> referential integrity violation - key in A still
referenced from B.

Thank you,

Leonid Furman.

pgsql-bugs by date:

Previous
From: Thomas Lockhart
Date:
Subject: Re: Turkish locale bug
Next
From: "Jeffrey F. Lawhorn"
Date:
Subject: regression test problems