Movatterモバイル変換


[0]ホーム

URL:


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

Sign up
Appearance settings

Commit4828445

Browse files
committed
Clarify documentation of age() functions.
1 parent5374d09 commit4828445

File tree

1 file changed

+10
-9
lines changed

1 file changed

+10
-9
lines changed

‎doc/src/sgml/func.sgml

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!--
2-
$PostgreSQL: pgsql/doc/src/sgml/func.sgml,v 1.224 2004/11/27 21:27:06 petere Exp $
2+
$PostgreSQL: pgsql/doc/src/sgml/func.sgml,v 1.225 2004/12/01 19:32:12 tgl Exp $
33
PostgreSQL documentation
44
-->
55

@@ -4877,19 +4877,20 @@ substring('foobar' from 'o(.)b') <lineannotation>o</lineannotation>
48774877

48784878
<tbody>
48794879
<row>
4880-
<entry><literal><function>age</function>(<type>timestamp</type>)</literal></entry>
4880+
<entry><literal><function>age</function>(<type>timestamp</type>, <type>timestamp</type>)</literal></entry>
48814881
<entry><type>interval</type></entry>
4882-
<entry>Subtract from today</entry>
4883-
<entry><literal>age(timestamp '1957-06-13')</literal></entry>
4884-
<entry><literal>43 years 8 mons 3 days</literal></entry>
4882+
<entry>Subtract arguments, producing a <quote>symbolic</> result that
4883+
uses years and months</entry>
4884+
<entry><literal>age(timestamp '2001-04-10', timestamp '1957-06-13')</literal></entry>
4885+
<entry><literal>43 years 9 mons 27 days</literal></entry>
48854886
</row>
48864887

48874888
<row>
4888-
<entry><literal><function>age</function>(<type>timestamp</type>, <type>timestamp</type>)</literal></entry>
4889+
<entry><literal><function>age</function>(<type>timestamp</type>)</literal></entry>
48894890
<entry><type>interval</type></entry>
4890-
<entry>Subtractarguments</entry>
4891-
<entry><literal>age('2001-04-10',timestamp '1957-06-13')</literal></entry>
4892-
<entry><literal>43 years9 mons27 days</literal></entry>
4891+
<entry>Subtractfrom <function>current_date</function></entry>
4892+
<entry><literal>age(timestamp '1957-06-13')</literal></entry>
4893+
<entry><literal>43 years8 mons3 days</literal></entry>
48934894
</row>
48944895

48954896
<row>

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp