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

Commit7b53b45

Browse files
committed
Update interval documenation to mention the storage system used.
1 parent2ddac94 commit7b53b45

File tree

1 file changed

+16
-5
lines changed

1 file changed

+16
-5
lines changed

‎doc/src/sgml/datatype.sgml

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!--
2-
$PostgreSQL: pgsql/doc/src/sgml/datatype.sgml,v 1.163 2005/10/2219:33:57 tgl Exp $
2+
$PostgreSQL: pgsql/doc/src/sgml/datatype.sgml,v 1.164 2005/12/2221:45:19 momjian Exp $
33
-->
44

55
<chapter id="datatype">
@@ -1841,9 +1841,20 @@ January 8 04:05:06 1999 PST
18411841
</para>
18421842

18431843
<para>
1844-
The optional precision
1845-
<replaceable>p</replaceable> should be between 0 and 6, and
1846-
defaults to the precision of the input literal.
1844+
The optional subsecond precision <replaceable>p</replaceable> should
1845+
be between 0 and 6, and defaults to the precision of the input literal.
1846+
</para>
1847+
1848+
<para>
1849+
Internally <type>interval</> values are stored as months, days,
1850+
and seconds. This is done because the number of days in a month
1851+
varies, and a day can have 23 or 25 hours if a daylight savings
1852+
time adjustment is involved. Because intervals are usually created
1853+
from constant strings or <type>timestamp</> subtraction, this
1854+
storage method works well in most cases. Functions
1855+
<function>justify_days</> and <function>justify_hours</> are
1856+
available for adjusting days and hours that overflow their normal
1857+
periods.
18471858
</para>
18481859
</sect3>
18491860

@@ -1936,7 +1947,7 @@ January 8 04:05:06 1999 PST
19361947
<literal>CURRENT_DATE</literal>, <literal>CURRENT_TIME</literal>,
19371948
<literal>CURRENT_TIMESTAMP</literal>, <literal>LOCALTIME</literal>,
19381949
<literal>LOCALTIMESTAMP</literal>. The latter four accept an
1939-
optional precision specification. (See <xref
1950+
optionalsubsecondprecision specification. (See <xref
19401951
linkend="functions-datetime-current">.) Note however that these are
19411952
SQL functions and are <emphasis>not</> recognized as data input strings.
19421953
</para>

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp