Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 5ccf322

Browse files
committed
doc: Make SQL command names in the catalog documentation links
In passing, fix the initdb references to be <application> rather than <command>, which is what we normally use. Author: Dagfinn Ilmari Mannsåker <ilmari@ilmari.org> Discussion: https://www.postgresql.org/message-id/flat/87mu5xqc11.fsf@wibble.ilmari.org
1 parent cb6eb4a commit 5ccf322

File tree

1 file changed

+56
-54
lines changed

1 file changed

+56
-54
lines changed

doc/src/sgml/catalogs.sgml

Lines changed: 56 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -1966,9 +1966,9 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
19661966
<para>
19671967
Size of the on-disk representation of this table in pages (of size
19681968
<symbol>BLCKSZ</symbol>). This is only an estimate used by the
1969-
planner. It is updated by <command>VACUUM</command>,
1970-
<command>ANALYZE</command>, and a few DDL commands such as
1971-
<command>CREATE INDEX</command>.
1969+
planner. It is updated by <xref linkend="sql-vacuum"/>,
1970+
<xref linkend="sql-analyze"/>, and a few DDL commands such as
1971+
<xref linkend="sql-createindex"/>.
19721972
</para></entry>
19731973
</row>
19741974

@@ -1978,9 +1978,9 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
19781978
</para>
19791979
<para>
19801980
Number of live rows in the table. This is only an estimate used by
1981-
the planner. It is updated by <command>VACUUM</command>,
1982-
<command>ANALYZE</command>, and a few DDL commands such as
1983-
<command>CREATE INDEX</command>.
1981+
the planner. It is updated by <xref linkend="sql-vacuum"/>,
1982+
<xref linkend="sql-analyze"/>, and a few DDL commands such as
1983+
<xref linkend="sql-createindex"/>.
19841984
If the table has never yet been vacuumed or
19851985
analyzed, <structfield>reltuples</structfield>
19861986
contains <literal>-1</literal> indicating that the row count is
@@ -1995,9 +1995,9 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
19951995
<para>
19961996
Number of pages that are marked all-visible in the table's
19971997
visibility map. This is only an estimate used by the
1998-
planner. It is updated by <command>VACUUM</command>,
1999-
<command>ANALYZE</command>, and a few DDL commands such as
2000-
<command>CREATE INDEX</command>.
1998+
planner. It is updated by <xref linkend="sql-vacuum"/>,
1999+
<xref linkend="sql-analyze"/>, and a few DDL commands such as
2000+
<xref linkend="sql-createindex"/>.
20012001
</para></entry>
20022002
</row>
20032003

@@ -2241,8 +2241,8 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
22412241
lazily: they are guaranteed to be true if that's the correct state, but
22422242
may not be reset to false immediately when the condition is no longer
22432243
true. For example, <structfield>relhasindex</structfield> is set by
2244-
<command>CREATE INDEX</command>, but it is never cleared by
2245-
<command>DROP INDEX</command>. Instead, <command>VACUUM</command> clears
2244+
<xref linkend="sql-createindex"/>, but it is never cleared by
2245+
<xref linkend="sql-dropindex"/>. Instead, <xref linkend="sql-vacuum"/> clears
22462246
<structfield>relhasindex</structfield> if it finds the table has no indexes. This
22472247
arrangement avoids race conditions and improves concurrency.
22482248
</para>
@@ -2419,8 +2419,8 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
24192419
</para>
24202420

24212421
<para>
2422-
User-defined constraint triggers (created with <command>CREATE CONSTRAINT
2423-
TRIGGER</command>) also give rise to an entry in this table.
2422+
User-defined constraint triggers (created with <link linkend="sql-createtrigger">
2423+
<command>CREATE CONSTRAINT TRIGGER</command></link>) also give rise to an entry in this table.
24242424
</para>
24252425

24262426
<para>
@@ -3425,7 +3425,7 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
34253425
the referenced object (see
34263426
<link linkend="catalog-pg-extension"><structname>pg_extension</structname></link>).
34273427
The dependent object can be dropped only via
3428-
<command>DROP EXTENSION</command> on the referenced object.
3428+
<xref linkend="sql-dropextension"/> on the referenced object.
34293429
Functionally this dependency type acts the same as
34303430
an <literal>INTERNAL</literal> dependency, but it's kept separate for
34313431
clarity and to simplify <application>pg_dump</application>.
@@ -3456,7 +3456,7 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
34563456
There is no dependent object; this type of entry is a signal
34573457
that the system itself depends on the referenced object, and so
34583458
that object must never be deleted. Entries of this type are
3459-
created only by <command>initdb</command>. The columns for the
3459+
created only by <application>initdb</application>. The columns for the
34603460
dependent object contain zeroes.
34613461
</para>
34623462
</listitem>
@@ -4285,7 +4285,7 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
42854285
<para>
42864286
If true, the index is currently valid for queries. False means the
42874287
index is possibly incomplete: it must still be modified by
4288-
<command>INSERT</command>/<command>UPDATE</command> operations, but it cannot safely
4288+
<xref linkend="sql-insert"/>/<xref linkend="sql-update"/> operations, but it cannot safely
42894289
be used for queries. If it is unique, the uniqueness property is not
42904290
guaranteed true either.
42914291
</para></entry>
@@ -4309,7 +4309,7 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
43094309
</para>
43104310
<para>
43114311
If true, the index is currently ready for inserts. False means the
4312-
index must be ignored by <command>INSERT</command>/<command>UPDATE</command>
4312+
index must be ignored by <xref linkend="sql-insert"/>/<xref linkend="sql-update"/>
43134313
operations.
43144314
</para></entry>
43154315
</row>
@@ -4330,8 +4330,8 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
43304330
</para>
43314331
<para>
43324332
If true this index has been chosen as <quote>replica identity</quote>
4333-
using <command>ALTER TABLE ... REPLICA IDENTITY USING INDEX
4334-
...</command>
4333+
using <link linkend="sql-altertable-replica-identity"><command>ALTER TABLE ...
4334+
REPLICA IDENTITY USING INDEX ...</command></link>
43354335
</para></entry>
43364336
</row>
43374337

@@ -4504,11 +4504,11 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
45044504
<para>
45054505
Objects can have initial privileges either by having those privileges set
45064506
when the system is initialized (by <application>initdb</application>) or when the
4507-
object is created during a <command>CREATE EXTENSION</command> and the
4508-
extension script sets initial privileges using the <command>GRANT</command>
4507+
object is created during a <xref linkend="sql-createextension"/> and the
4508+
extension script sets initial privileges using the <xref linkend="sql-grant"/>
45094509
system. Note that the system will automatically handle recording of the
45104510
privileges during the extension script and that extension authors need
4511-
only use the <command>GRANT</command> and <command>REVOKE</command>
4511+
only use the <xref linkend="sql-grant"/> and <xref linkend="sql-revoke"/>
45124512
statements in their script to have the privileges recorded. The
45134513
<literal>privtype</literal> column indicates if the initial privilege was
45144514
set by <application>initdb</application> or during a
@@ -5564,10 +5564,10 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
55645564
</para>
55655565
<para>
55665566
The command type to which the policy is applied:
5567-
<literal>r</literal> for <command>SELECT</command>,
5568-
<literal>a</literal> for <command>INSERT</command>,
5569-
<literal>w</literal> for <command>UPDATE</command>,
5570-
<literal>d</literal> for <command>DELETE</command>,
5567+
<literal>r</literal> for <xref linkend="sql-select"/>,
5568+
<literal>a</literal> for <xref linkend="sql-insert"/>,
5569+
<literal>w</literal> for <xref linkend="sql-update"/>,
5570+
<literal>d</literal> for <xref linkend="sql-delete"/>,
55715571
or <literal>*</literal> for all
55725572
</para></entry>
55735573
</row>
@@ -6075,7 +6075,7 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
60756075
<structfield>pubinsert</structfield> <type>bool</type>
60766076
</para>
60776077
<para>
6078-
If true, <command>INSERT</command> operations are replicated for
6078+
If true, <xref linkend="sql-insert"/> operations are replicated for
60796079
tables in the publication.
60806080
</para></entry>
60816081
</row>
@@ -6085,7 +6085,7 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
60856085
<structfield>pubupdate</structfield> <type>bool</type>
60866086
</para>
60876087
<para>
6088-
If true, <command>UPDATE</command> operations are replicated for
6088+
If true, <xref linkend="sql-update"/> operations are replicated for
60896089
tables in the publication.
60906090
</para></entry>
60916091
</row>
@@ -6095,7 +6095,7 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
60956095
<structfield>pubdelete</structfield> <type>bool</type>
60966096
</para>
60976097
<para>
6098-
If true, <command>DELETE</command> operations are replicated for
6098+
If true, <xref linkend="sql-delete"/> operations are replicated for
60996099
tables in the publication.
61006100
</para></entry>
61016101
</row>
@@ -6105,7 +6105,7 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
61056105
<structfield>pubtruncate</structfield> <type>bool</type>
61066106
</para>
61076107
<para>
6108-
If true, <command>TRUNCATE</command> operations are replicated for
6108+
If true, <xref linkend="sql-truncate"/> operations are replicated for
61096109
tables in the publication.
61106110
</para></entry>
61116111
</row>
@@ -6408,9 +6408,9 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
64086408
<structfield>ev_type</structfield> <type>char</type>
64096409
</para>
64106410
<para>
6411-
Event type that the rule is for: 1 = <command>SELECT</command>, 2 =
6412-
<command>UPDATE</command>, 3 = <command>INSERT</command>, 4 =
6413-
<command>DELETE</command>
6411+
Event type that the rule is for: 1 = <xref linkend="sql-select"/>, 2 =
6412+
<xref linkend="sql-update"/>, 3 = <xref linkend="sql-insert"/>, 4 =
6413+
<xref linkend="sql-delete"/>
64146414
</para></entry>
64156415
</row>
64166416

@@ -6832,7 +6832,7 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
68326832
There is no dependent object; this type of entry is a signal
68336833
that the system itself depends on the referenced object, and so
68346834
that object must never be deleted. Entries of this type are
6835-
created only by <command>initdb</command>. The columns for the
6835+
created only by <application>initdb</application>. The columns for the
68366836
dependent object contain zeroes.
68376837
</para>
68386838
</listitem>
@@ -7336,9 +7336,9 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
73367336

73377337
<para>
73387338
The <structname>pg_statistic_ext</structname> entry is filled in
7339-
completely during <command>CREATE STATISTICS</command>, but the actual
7339+
completely during <xref linkend="sql-createstatistics"/>, but the actual
73407340
statistical values are not computed then.
7341-
Subsequent <command>ANALYZE</command> commands compute the desired values
7341+
Subsequent <xref linkend="sql-analyze"/> commands compute the desired values
73427342
and populate an entry in the
73437343
<link linkend="catalog-pg-statistic-ext-data"><structname>pg_statistic_ext_data</structname></link>
73447344
catalog.
@@ -7590,8 +7590,9 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
75907590

75917591
<para>
75927592
This catalog only contains tables known to the subscription after running
7593-
either <command>CREATE SUBSCRIPTION</command> or
7594-
<command>ALTER SUBSCRIPTION ... REFRESH PUBLICATION</command>.
7593+
either <xref linkend="sql-createsubscription"/> or
7594+
<link linkend="sql-altersubscription"><command>ALTER SUBSCRIPTION ... REFRESH
7595+
PUBLICATION</command></link>.
75957596
</para>
75967597

75977598
<table>
@@ -8837,7 +8838,7 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
88378838
(references <link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.<structfield>oid</structfield>)
88388839
</para>
88398840
<para>
8840-
Custom <command>ANALYZE</command> function, or 0 to use the standard function
8841+
Custom <xref linkend="sql-analyze"/> function, or 0 to use the standard function
88418842
</para></entry>
88428843
</row>
88438844

@@ -10324,7 +10325,7 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
1032410325
<structfield>indexdef</structfield> <type>text</type>
1032510326
</para>
1032610327
<para>
10327-
Index definition (a reconstructed <command>CREATE INDEX</command>
10328+
Index definition (a reconstructed <xref linkend="sql-createindex"/>
1032810329
command)
1032910330
</para></entry>
1033010331
</row>
@@ -10779,7 +10780,7 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1077910780
<structfield>definition</structfield> <type>text</type>
1078010781
</para>
1078110782
<para>
10782-
Materialized view definition (a reconstructed <command>SELECT</command> query)
10783+
Materialized view definition (a reconstructed <xref linkend="sql-select"/> query)
1078310784
</para></entry>
1078410785
</row>
1078510786
</tbody>
@@ -10949,7 +10950,7 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1094910950
<para>
1095010951
The query string submitted by the client to create this
1095110952
prepared statement. For prepared statements created via SQL,
10952-
this is the <command>PREPARE</command> statement submitted by
10953+
this is the <xref linkend="sql-prepare"/> statement submitted by
1095310954
the client. For prepared statements created via the
1095410955
frontend/backend protocol, this is the text of the prepared
1095510956
statement itself.
@@ -10983,7 +10984,7 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1098310984
</para>
1098410985
<para>
1098510986
<literal>true</literal> if the prepared statement was created
10986-
via the <command>PREPARE</command> SQL command;
10987+
via the <xref linkend="sql-prepare"/> SQL command;
1098710988
<literal>false</literal> if the statement was prepared via the
1098810989
frontend/backend protocol
1098910990
</para></entry>
@@ -12114,7 +12115,7 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1211412115
<structfield>reset_val</structfield> <type>text</type>
1211512116
</para>
1211612117
<para>
12117-
Value that <command>RESET</command> would reset the parameter to
12118+
Value that <xref linkend="sql-reset"/> would reset the parameter to
1211812119
in the current session
1211912120
</para></entry>
1212012121
</row>
@@ -12172,7 +12173,7 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1217212173
These settings cannot be changed directly; they reflect internally
1217312174
determined values. Some of them may be adjustable by rebuilding the
1217412175
server with different configuration options, or by changing options
12175-
supplied to <command>initdb</command>.
12176+
supplied to <application>initdb</application>.
1217612177
</para>
1217712178
</listitem>
1217812179
</varlistentry>
@@ -12247,7 +12248,7 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1224712248
<listitem>
1224812249
<para>
1224912250
These settings can be set from <filename>postgresql.conf</filename>,
12250-
or within a session via the <command>SET</command> command; but only superusers
12251+
or within a session via the <xref linkend="sql-set"/> command; but only superusers
1225112252
can change them via <command>SET</command>. Changes in
1225212253
<filename>postgresql.conf</filename> will affect existing sessions
1225312254
only if no session-local value has been established with <command>SET</command>.
@@ -12260,7 +12261,7 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1226012261
<listitem>
1226112262
<para>
1226212263
These settings can be set from <filename>postgresql.conf</filename>,
12263-
or within a session via the <command>SET</command> command. Any user is
12264+
or within a session via the <xref linkend="sql-set"/> command. Any user is
1226412265
allowed to change their session-local value. Changes in
1226512266
<filename>postgresql.conf</filename> will affect existing sessions
1226612267
only if no session-local value has been established with <command>SET</command>.
@@ -12276,7 +12277,7 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1227612277

1227712278
<para>
1227812279
The <structname>pg_settings</structname> view cannot be inserted into or
12279-
deleted from, but it can be updated. An <command>UPDATE</command> applied
12280+
deleted from, but it can be updated. An <xref linkend="sql-update"/> applied
1228012281
to a row of <structname>pg_settings</structname> is equivalent to executing
1228112282
the <xref linkend="sql-set"/> command on that named
1228212283
parameter. The change only affects the value used by the current
@@ -12620,7 +12621,7 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1262012621
If greater than zero, the estimated number of distinct values in the
1262112622
column. If less than zero, the negative of the number of distinct
1262212623
values divided by the number of rows. (The negated form is used when
12623-
<command>ANALYZE</command> believes that the number of distinct values is
12624+
<xref linkend="sql-analyze"/> believes that the number of distinct values is
1262412625
likely to increase as the table grows; the positive form is used when
1262512626
the column seems to have a fixed number of possible values.) For
1262612627
example, -1 indicates a unique column in which the number of distinct
@@ -12718,7 +12719,8 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1271812719

1271912720
<para>
1272012721
The maximum number of entries in the array fields can be controlled on a
12721-
column-by-column basis using the <command>ALTER TABLE SET STATISTICS</command>
12722+
column-by-column basis using the <link linkend="sql-altertable"><command>ALTER
12723+
TABLE SET STATISTICS</command></link>
1272212724
command, or globally by setting the
1272312725
<xref linkend="guc-default-statistics-target"/> run-time parameter.
1272412726
</para>
@@ -12843,7 +12845,7 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1284312845
than zero, the estimated number of distinct values in the combination.
1284412846
If less than zero, the negative of the number of distinct values divided
1284512847
by the number of rows.
12846-
(The negated form is used when <command>ANALYZE</command> believes that
12848+
(The negated form is used when <xref linkend="sql-analyze"/> believes that
1284712849
the number of distinct values is likely to increase as the table grows;
1284812850
the positive form is used when the column seems to have a fixed number
1284912851
of possible values.) For example, -1 indicates a unique combination of
@@ -12908,8 +12910,8 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1290812910

1290912911
<para>
1291012912
The maximum number of entries in the array fields can be controlled on a
12911-
column-by-column basis using the <command>ALTER TABLE SET STATISTICS</command>
12912-
command, or globally by setting the
12913+
column-by-column basis using the <link linkend="sql-altertable"><command>ALTER
12914+
TABLE SET STATISTICS</command></link> command, or globally by setting the
1291312915
<xref linkend="guc-default-statistics-target"/> run-time parameter.
1291412916
</para>
1291512917

@@ -13471,7 +13473,7 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1347113473
<structfield>definition</structfield> <type>text</type>
1347213474
</para>
1347313475
<para>
13474-
View definition (a reconstructed <command>SELECT</command> query)
13476+
View definition (a reconstructed <xref linkend="sql-select"/> query)
1347513477
</para></entry>
1347613478
</row>
1347713479
</tbody>

0 commit comments

Comments
 (0)