diff options
| author | David Rowley <drowley@postgresql.org> | 2025-11-06 16:03:02 +1300 |
|---|---|---|
| committer | David Rowley <drowley@postgresql.org> | 2025-11-06 16:03:02 +1300 |
| commit | 49d43faa835f3c6817be9fc0b98bec0d661c2587 (patch) | |
| tree | 7e05c18da6489861271e5e84d260ac226a362275 /doc/src/sgml/func/func-datetime.sgml | |
| parent | 6d0eba66275b125bf634bbdffda90c70856e3f93 (diff) | |
Doc: use uppercase keywords in SQLs
Use uppercase SQL keywords consistently throughout the documentation to
ease reading. Also add whitespace in a couple of places where it
improves readability.
Author: Erik Wienhold <ewie@ewie.name>
Reviewed-by: David Rowley <dgrowleyml@gmail.com>
Discussion: https://postgr.es/m/82eb512b-8ed2-46be-b311-54ffd26978c4%40ewie.name
Diffstat (limited to 'doc/src/sgml/func/func-datetime.sgml')
| -rw-r--r-- | doc/src/sgml/func/func-datetime.sgml | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/doc/src/sgml/func/func-datetime.sgml b/doc/src/sgml/func/func-datetime.sgml index 8cd7150b0d3..39dddde4fe1 100644 --- a/doc/src/sgml/func/func-datetime.sgml +++ b/doc/src/sgml/func/func-datetime.sgml @@ -602,28 +602,28 @@ <indexterm> <primary>extract</primary> </indexterm> - <function>extract</function> ( <parameter>field</parameter> <literal>from</literal> <type>timestamp</type> ) + <function>extract</function> ( <parameter>field</parameter> <literal>FROM</literal> <type>timestamp</type> ) <returnvalue>numeric</returnvalue> </para> <para> Get timestamp subfield; see <xref linkend="functions-datetime-extract"/> </para> <para> - <literal>extract(hour from timestamp '2001-02-16 20:38:40')</literal> + <literal>extract(hour FROM timestamp '2001-02-16 20:38:40')</literal> <returnvalue>20</returnvalue> </para></entry> </row> <row> <entry role="func_table_entry"><para role="func_signature"> - <function>extract</function> ( <parameter>field</parameter> <literal>from</literal> <type>interval</type> ) + <function>extract</function> ( <parameter>field</parameter> <literal>FROM</literal> <type>interval</type> ) <returnvalue>numeric</returnvalue> </para> <para> Get interval subfield; see <xref linkend="functions-datetime-extract"/> </para> <para> - <literal>extract(month from interval '2 years 3 months')</literal> + <literal>extract(month FROM interval '2 years 3 months')</literal> <returnvalue>3</returnvalue> </para></entry> </row> @@ -1849,7 +1849,7 @@ SELECT date_bin('15 minutes', TIMESTAMP '2020-02-11 15:44:17', TIMESTAMP '2001-0 value is in the named time zone. </para> <para> - <literal>timestamp '2001-02-16 20:38:40' at time zone 'America/Denver'</literal> + <literal>timestamp '2001-02-16 20:38:40' AT TIME ZONE 'America/Denver'</literal> <returnvalue>2001-02-17 03:38:40+00</returnvalue> </para></entry> </row> @@ -1881,7 +1881,7 @@ SELECT date_bin('15 minutes', TIMESTAMP '2020-02-11 15:44:17', TIMESTAMP '2001-0 appear in that zone. </para> <para> - <literal>timestamp with time zone '2001-02-16 20:38:40-05' at time zone 'America/Denver'</literal> + <literal>timestamp with time zone '2001-02-16 20:38:40-05' AT TIME ZONE 'America/Denver'</literal> <returnvalue>2001-02-16 18:38:40</returnvalue> </para></entry> </row> @@ -1913,7 +1913,7 @@ SELECT date_bin('15 minutes', TIMESTAMP '2020-02-11 15:44:17', TIMESTAMP '2001-0 offset for the named destination zone. </para> <para> - <literal>time with time zone '05:34:17-05' at time zone 'UTC'</literal> + <literal>time with time zone '05:34:17-05' AT TIME ZONE 'UTC'</literal> <returnvalue>10:34:17+00</returnvalue> </para></entry> </row> |
