I've put together a small patch to provide a schema name in an fk violation in deference to the todo item "Report the schema along table name in a referential failure error message"
The error message only contains the schema if the table name being referenced is non-unique or not present in the search_path. It passes a make check, and I've added a couple of test cases which expect the schema's output in the cases mentioned above. Also, it looks like Rev 1.113 added spaces to the values specified in errdetail for failed FK violations, but the testoutput wasn't updated. I haven't included that in this patch for clarity, but it probably should be corrected. Have at it, -George
fk_schemas.patch
Description: Binary data
-- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers