Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit da486d3

Browse filesBrowse files
committed
doc: Clarify that pg_attrdef also stores generation expressions
This was documented with pg_attribute but not with pg_attrdef. Reported-by: jian he <jian.universality@gmail.com> Discussion: https://www.postgresql.org/message-id/CACJufxE+E-iYmBnZVZHiYA+WpyZZVv7BfiBLpo=T70EZHDU9rw@mail.gmail.com
1 parent 2357c92 commit da486d3
Copy full SHA for da486d3

File tree

Expand file treeCollapse file tree

1 file changed

+6
-5
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+6
-5
lines changed

‎doc/src/sgml/catalogs.sgml

Copy file name to clipboardExpand all lines: doc/src/sgml/catalogs.sgml
+6-5Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1032,10 +1032,11 @@
10321032

10331033
<para>
10341034
The catalog <structname>pg_attrdef</structname> stores column default
1035-
values. The main information about columns is stored in
1036-
<link linkend="catalog-pg-attribute"><structname>pg_attribute</structname></link>.
1037-
Only columns for which a default value has been explicitly set will have
1038-
an entry here.
1035+
expressions and generation expressions. The main information about columns
1036+
is stored in <link
1037+
linkend="catalog-pg-attribute"><structname>pg_attribute</structname></link>.
1038+
Only columns for which a default expression or generation expression has
1039+
been explicitly set will have an entry here.
10391040
</para>
10401041

10411042
<table>
@@ -1087,7 +1088,7 @@
10871088
<structfield>adbin</structfield> <type>pg_node_tree</type>
10881089
</para>
10891090
<para>
1090-
The column default value, in <function>nodeToString()</function>
1091+
The column default or generation expression, in <function>nodeToString()</function>
10911092
representation. Use <literal>pg_get_expr(adbin, adrelid)</literal> to
10921093
convert it to an SQL expression.
10931094
</para></entry>

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.