diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2003-12-01 20:35:04 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2003-12-01 20:35:04 +0000 |
commit | e1d2c43a22e7f138cd7edb7dc168ce09c823c04a (patch) | |
tree | 035978f3fb106119bf2492c1946429e18ef1b096 | |
parent | a8cdd6459c598940919d79691d60c327dc365b37 (diff) |
Minor wordsmithing in datetime docs to try to address gripes raised by
cnliou.
-rw-r--r-- | doc/src/sgml/datatype.sgml | 33 | ||||
-rw-r--r-- | doc/src/sgml/datetime.sgml | 18 |
2 files changed, 31 insertions, 20 deletions
diff --git a/doc/src/sgml/datatype.sgml b/doc/src/sgml/datatype.sgml index 11d4c5921aa..37fdc653ac1 100644 --- a/doc/src/sgml/datatype.sgml +++ b/doc/src/sgml/datatype.sgml @@ -1,5 +1,5 @@ <!-- -$Header: /cvsroot/pgsql/doc/src/sgml/datatype.sgml,v 1.128.2.4 2003/11/30 20:53:43 joe Exp $ +$Header: /cvsroot/pgsql/doc/src/sgml/datatype.sgml,v 1.128.2.5 2003/12/01 20:35:04 tgl Exp $ --> <chapter id="datatype"> @@ -1301,7 +1301,7 @@ SELECT b, char_length(b) FROM test2; <entry>8 bytes</entry> <entry>both date and time</entry> <entry>4713 BC</entry> - <entry>AD 5874897</entry> + <entry>5874897 AD</entry> <entry>1 microsecond / 14 digits</entry> </row> <row> @@ -1309,7 +1309,7 @@ SELECT b, char_length(b) FROM test2; <entry>8 bytes</entry> <entry>both date and time, with time zone</entry> <entry>4713 BC</entry> - <entry>AD 5874897</entry> + <entry>5874897 AD</entry> <entry>1 microsecond / 14 digits</entry> </row> <row> @@ -1348,6 +1348,14 @@ SELECT b, char_length(b) FROM test2; </tgroup> </table> + <note> + <para> + Prior to <productname>PostgreSQL</productname> 7.3, writing just + <type>timestamp</type> was equivalent to <type>timestamp with + time zone</type>. This was changed for SQL compliance. + </para> + </note> + <para> <type>time</type>, <type>timestamp</type>, and <type>interval</type> accept an optional precision value @@ -1363,23 +1371,16 @@ SELECT b, char_length(b) FROM test2; When <type>timestamp</> values are stored as double precision floating-point numbers (currently the default), the effective limit of precision may be less than 6. <type>timestamp</type> values are stored as seconds - since 2000-01-01, and microsecond precision is achieved for dates within - a few years of 2000-01-01, but the precision degrades for dates further - away. When <type>timestamp</type> values are stored as eight-byte integers (a compile-time + before or after midnight 2000-01-01. Microsecond precision is achieved for + dates within a few years of 2000-01-01, but the precision degrades for + dates further away. When <type>timestamp</type> values are stored as + eight-byte integers (a compile-time option), microsecond precision is available over the full range of - values. However eight-byte integer timestamps have a reduced range of - dates from 4713 BC up to 294276 AD. + values. However eight-byte integer timestamps have a more limited range of + dates than shown above: from 4713 BC up to 294276 AD. </para> </note> - <note> - <para> - Prior to <productname>PostgreSQL</productname> 7.3, writing just - <type>timestamp</type> was equivalent to <type>timestamp with - time zone</type>. This was changed for SQL compliance. - </para> - </note> - <para> For the <type>time</type> types, the allowed range of <replaceable>p</replaceable> is from 0 to 6 when eight-byte integer diff --git a/doc/src/sgml/datetime.sgml b/doc/src/sgml/datetime.sgml index 67b71636abd..3cc00a10184 100644 --- a/doc/src/sgml/datetime.sgml +++ b/doc/src/sgml/datetime.sgml @@ -1,5 +1,5 @@ <!-- -$Header: /cvsroot/pgsql/doc/src/sgml/datetime.sgml,v 2.36.2.1 2003/11/06 22:21:55 tgl Exp $ +$Header: /cvsroot/pgsql/doc/src/sgml/datetime.sgml,v 2.36.2.2 2003/12/01 20:35:04 tgl Exp $ --> <appendix id="datetime-appendix"> @@ -370,9 +370,10 @@ $Header: /cvsroot/pgsql/doc/src/sgml/datetime.sgml,v 2.36.2.1 2003/11/06 22:21:5 <para> <xref linkend="datetime-timezone-table"> shows the time zone - abbreviations recognized by <productname>PostgreSQL</productname>. - <productname>PostgreSQL</productname> contains internal tabular - information for time zone decoding, since there is no standard + abbreviations recognized by <productname>PostgreSQL</productname> + in date/time input values. + <productname>PostgreSQL</productname> uses internal tables + for time zone input decoding, since there is no standard operating system interface to provide access to general, cross-time zone information. The underlying operating system <emphasis>is</emphasis> used to provide time zone information for @@ -380,6 +381,15 @@ $Header: /cvsroot/pgsql/doc/src/sgml/datetime.sgml,v 2.36.2.1 2003/11/06 22:21:5 </para> <para> + Keep in mind also that the time zone names + recognized by <command>SET TIMEZONE</> are operating-system + dependent and may have little to do with <xref + linkend="datetime-timezone-table">. For example, some systems + recognize values like <literal>'Europe/Rome'</> in <command>SET + TIMEZONE</>. + </para> + + <para> The table is organized by time zone offset from <acronym>UTC</>, rather than alphabetically. This is intended to facilitate matching local usage with recognized abbreviations for cases where |