Update docs in fdwhandler.sgml

Started by Etsuro Fujitaover 10 years ago3 messages
#1Etsuro Fujita
fujita.etsuro@lab.ntt.co.jp
1 attachment(s)

Hi,

Since we now allow CHECK constraints to be placed on foreign tables, not
only NOT NULL, I think it'd be better to update docs on considerations
about constraints on foreign tables in fdwhandler.sgml, so as to provide
more general considerations. Please find attached a patch.

Best regards,
Etsuro Fujita

Attachments:

doc-fdw-constraints.patchtext/x-diff; name=doc-fdw-constraints.patchDownload
*** a/doc/src/sgml/fdwhandler.sgml
--- b/doc/src/sgml/fdwhandler.sgml
***************
*** 242,254 **** IterateForeignScan (ForeignScanState *node);
  
      <para>
       Note that <productname>PostgreSQL</productname>'s executor doesn't care
!      whether the rows returned violate any <literal>NOT NULL</literal>
!      constraints that were defined on the foreign table columns &mdash; but
!      the planner does care, and may optimize queries incorrectly if
!      <literal>NULL</> values are present in a column declared not to contain
!      them.  If a <literal>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).
      </para>
  
      <para>
--- 242,254 ----
  
      <para>
       Note that <productname>PostgreSQL</productname>'s executor doesn't care
!      whether the rows returned violate any constraints that were defined on
!      the foreign table &mdash; but the planner does care, and may optimize
!      queries incorrectly if there are rows visible in the foreign table that
!      do not satisfy a declared constraint.  If a constraint is violated when
!      the user has declared that the constraint should hold true, it may be
!      appropriate to raise an error (just as you would need to do in the case
!      of a data type mismatch).
      </para>
  
      <para>
#2Robert Haas
robertmhaas@gmail.com
In reply to: Etsuro Fujita (#1)
Re: Update docs in fdwhandler.sgml

On Tue, Apr 21, 2015 at 5:45 AM, Etsuro Fujita
<fujita.etsuro@lab.ntt.co.jp> wrote:

Since we now allow CHECK constraints to be placed on foreign tables, not
only NOT NULL, I think it'd be better to update docs on considerations
about constraints on foreign tables in fdwhandler.sgml, so as to provide
more general considerations. Please find attached a patch.

Looks good to me, so committed.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#3Etsuro Fujita
fujita.etsuro@lab.ntt.co.jp
In reply to: Robert Haas (#2)
Re: Update docs in fdwhandler.sgml

On 2015/04/22 6:50, Robert Haas wrote:

On Tue, Apr 21, 2015 at 5:45 AM, Etsuro Fujita
<fujita.etsuro@lab.ntt.co.jp> wrote:

Since we now allow CHECK constraints to be placed on foreign tables, not
only NOT NULL, I think it'd be better to update docs on considerations
about constraints on foreign tables in fdwhandler.sgml, so as to provide
more general considerations. Please find attached a patch.

Looks good to me, so committed.

Thanks!

Best regards,
Etsuro Fujita

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers