From: | Etsuro Fujita <fujita(dot)etsuro(at)lab(dot)ntt(dot)co(dot)jp> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | David Fetter <david(at)fetter(dot)org>, Robert Haas <robertmhaas(at)gmail(dot)com>, PG Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: CREATE FOREGIN TABLE LACUNA |
Date: | 2012-03-15 09:50:44 |
Message-ID: | 4F61BB74.6090208@lab.ntt.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
(2012/03/15 0:29), Tom Lane wrote:
> The posted patch for file_fdw takes the
> approach of silently filtering out rows for which they're not true,
> which is not obviously the right thing either --- quite aside from
> whether that's a sane semantics, it's not going to scale to foreign key
> constraints, and even for simple NOT NULL and CHECK constraints it
> results in a runtime penalty on selects, which is not what people would
> expect from a constraint.
I investigated DB2 a little bit. In DB2, the user can specify the
VALIDATE_DATA_FILE option as a generic option for an external table
attached to a data file, which specifies if the wrapper verifies that
the data file is sorted. How about introducing this kind of option to
file_fdw? It might be better that the default value for the option is
'false', and if the value is set to 'true', then file_fdw verifies NOT
NULL, CHECK, and foreign key constraints.
Best regards,
Etsuro Fujita
From | Date | Subject | |
---|---|---|---|
Next Message | Thom Brown | 2012-03-15 12:03:03 | Re: Command Triggers, patch v11 |
Previous Message | Yeb Havinga | 2012-03-15 09:16:03 | Re: EquivalenceClasses and subqueries and PlaceHolderVars, oh my |