Skip to content

Commit 348f57c

Browse files
committed
doc: Add note about generated columns in foreign tables
Explain that it is not enforced that querying a generated column returns data that is consistent with the data that was stored. This is similar to the note about constraints nearby. Reported-by: Amit Langote <amitlangote09@gmail.com>
1 parent 119dcfa commit 348f57c

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

doc/src/sgml/ref/create_foreign_table.sgml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -350,6 +350,16 @@ CHECK ( <replaceable class="parameter">expression</replaceable> ) [ NO INHERIT ]
350350
reality.
351351
</para>
352352

353+
<para>
354+
Similar considerations apply to generated columns. Stored generated
355+
columns are computed on insert or update on the local
356+
<productname>PostgreSQL</productname> server and handed to the
357+
foreign-data wrapper for writing out to the foreign data store, but it is
358+
not enforced that a query of the foreign table returns values for stored
359+
generated columns that are consistent with the generation expression.
360+
Again, this might result in incorrect query results.
361+
</para>
362+
353363
<para>
354364
While rows can be moved from local partitions to a foreign-table partition
355365
(provided the foreign data wrapper supports tuple routing), they cannot be

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy