public inbox for [email protected]
help / color / mirror / Atom feedFrom: Bruce Momjian <[email protected]>
To: Eric Howe <[email protected]>
Cc: [email protected]
Subject: Re: Missing date_trunc docs
Date: Wed, 22 Jan 2014 22:27:29 -0500
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>
List-Unsubscribe: <mailto:[email protected]?body=unsub%20pgsql-docs>
On Fri, Jun 7, 2013 at 11:32:14AM -0700, Eric Howe wrote:
> In table 9-27 of the 9.2 docs:
>
> http://www.postgresql.org/docs/9.2/interactive/functions-datetime.html#FUNCTIONS-DATETIME-TABLE
>
> There is an entry for date_trunc(text, timestamp) but no entry for date_trunc(text, interval). The full docs for date_trunc:
>
> http://www.postgresql.org/docs/9.2/interactive/functions-datetime.html#FUNCTIONS-DATETIME-TRUNC
>
> do mention both the timestamp and interval forms of date_trunc but that's easy to miss if you're just scanning the function lists.
Thanks for the report. The attached patch has been applied and will
appear in PG 9.4. Sorry for the delay.
--
Bruce Momjian <[email protected]> http://momjian.us
EnterpriseDB http://enterprisedb.com
+ Everyone has their own god. +
--
Sent via pgsql-docs mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-docs
Attachments:
[text/x-diff] date_trunc.diff (1.0K, 2-date_trunc.diff)
download | inline diff:
diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml
new file mode 100644
index 53021c2..e79c479
*** a/doc/src/sgml/func.sgml
--- b/doc/src/sgml/func.sgml
*************** SELECT SUBSTRING('XY1234Z', 'Y*?([0-9]{1
*** 6570,6575 ****
--- 6570,6589 ----
<row>
<entry>
<indexterm>
+ <primary>date_trunc</primary>
+ </indexterm>
+ <literal><function>date_trunc(<type>text</type>, <type>interval</type>)</function></literal>
+ </entry>
+ <entry><type>interval</type></entry>
+ <entry>Truncate to specified precision; see also <xref linkend="functions-datetime-trunc">
+ </entry>
+ <entry><literal>date_trunc('hour', interval '2 days 3 hours 40 minutes')</literal></entry>
+ <entry><literal>2 days 03:00:00</literal></entry>
+ </row>
+
+ <row>
+ <entry>
+ <indexterm>
<primary>extract</primary>
</indexterm>
<literal><function>extract</function>(<parameter>field</parameter> from
view thread (2+ messages)
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected]
Subject: Re: Missing date_trunc docs
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox