diff options
author | Peter Eisentraut <peter@eisentraut.org> | 2020-10-03 16:16:51 +0200 |
---|---|---|
committer | Peter Eisentraut <peter@eisentraut.org> | 2020-10-03 16:40:02 +0200 |
commit | 9081bddbd75e4e8994ca243c820ca63387bd33f7 (patch) | |
tree | a9e9f66b96fa16067375262a99a39e4b9a501254 /doc/src/sgml/postgres-fdw.sgml | |
parent | 1a9388bd0fefccc81430192d0b2c87938bb62d38 (diff) | |
download | postgresql-9081bddbd75e4e8994ca243c820ca63387bd33f7.tar.gz postgresql-9081bddbd75e4e8994ca243c820ca63387bd33f7.zip |
Improve <xref> vs. <command> formatting in the documentation
SQL commands are generally marked up as <command>, except when a link
to a reference page is used using <xref>. But the latter doesn't
create monospace markup, so this looks strange especially when a
paragraph contains a mix of links and non-links.
We considered putting <command> in the <refentrytitle> on the target
side, but that creates some formatting side effects elsewhere.
Generally, it seems safer to solve this on the link source side.
We can't put the <xref> inside the <command>; the DTD doesn't allow
this. DocBook 5 would allow the <command> to have the linkend
attribute itself, but we are not there yet.
So to solve this for now, convert the <xref>s to <link> plus
<command>. This gives the correct look and also gives some more
flexibility what we can put into the link text (e.g., subcommands or
other clauses). In the future, these could then be converted to
DocBook 5 style.
I haven't converted absolutely all xrefs to SQL command reference
pages, only those where we care about the appearance of the link text
or where it was otherwise appropriate to make the appearance match a
bit better. Also in some cases, the links where repetitive, so in
those cases the links where just removed and replaced by a plain
<command>. In cases where we just want the link and don't
specifically care about the generated link text (typically phrased
"for further information see <xref ...>") the xref is kept.
Reported-by: Dagfinn Ilmari Mannsåker <ilmari@ilmari.org>
Discussion: https://www.postgresql.org/message-id/flat/87o8pco34z.fsf@wibble.ilmari.org
Diffstat (limited to 'doc/src/sgml/postgres-fdw.sgml')
-rw-r--r-- | doc/src/sgml/postgres-fdw.sgml | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/doc/src/sgml/postgres-fdw.sgml b/doc/src/sgml/postgres-fdw.sgml index 4efaf35d3c4..e6fd2143c10 100644 --- a/doc/src/sgml/postgres-fdw.sgml +++ b/doc/src/sgml/postgres-fdw.sgml @@ -456,14 +456,14 @@ OPTIONS (ADD password_required 'false'); <para> Note that constraints other than <literal>NOT NULL</literal> will never be imported from the remote tables. Although <productname>PostgreSQL</productname> - does support <literal>CHECK</literal> constraints on foreign tables, there is no + does support check constraints on foreign tables, there is no provision for importing them automatically, because of the risk that a constraint expression could evaluate differently on the local and remote - servers. Any such inconsistency in the behavior of a <literal>CHECK</literal> + servers. Any such inconsistency in the behavior of a check constraint could lead to hard-to-detect errors in query optimization. - So if you wish to import <literal>CHECK</literal> constraints, you must do so + So if you wish to import check constraints, you must do so manually, and you should verify the semantics of each one carefully. - For more detail about the treatment of <literal>CHECK</literal> constraints on + For more detail about the treatment of check constraints on foreign tables, see <xref linkend="sql-createforeigntable"/>. </para> @@ -705,7 +705,7 @@ CREATE FOREIGN TABLE foreign_table ( Column names must match as well, unless you attach <literal>column_name</literal> options to the individual columns to show how they are named in the remote table. - In many cases, use of <xref linkend="sql-importforeignschema"/> is + In many cases, use of <link linkend="sql-importforeignschema"><command>IMPORT FOREIGN SCHEMA</command></link> is preferable to constructing foreign table definitions manually. </para> </sect2> |