From: | Etsuro Fujita <fujita(dot)etsuro(at)lab(dot)ntt(dot)co(dot)jp> |
---|---|
To: | Pg Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | NOT NULL violation error handling in file_fdw |
Date: | 2012-03-12 10:21:06 |
Message-ID: | 4F5DCE12.60408@lab.ntt.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
According to the following documentation on IterateForeignScan() in
50.2. Foreign Data Wrapper Callback Routines, I have created a patch to
support the error handling in file_fdw. Please find attached a patch.
Note that PostgreSQL's executor doesn't care whether the rows
returned violate the NOT NULL constraints which were defined
on the foreign table columns - but the planner does care, and
may optimize queries incorrectly if NULL values are present
in a column declared not to contain them. If a NULL value is
encountered when the user has declared that none should be
present, it may be appropriate to raise an error (just as you
would need to do in the case of a data type mismatch).
Best regards,
Etsuro Fujita
Attachment | Content-Type | Size |
---|---|---|
file_fdw_notnull_v1.patch | text/plain | 3.1 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Heikki Linnakangas | 2012-03-12 10:58:51 | Re: Bug: walsender and high CPU usage |
Previous Message | Pavel Stehule | 2012-03-12 09:47:26 | Re: poll: CHECK TRIGGER? |