From: Tom Lane <tgl@sss.pgh.pa.us>
To: yoonghm@gmail.com
Cc: pgsql-bugs@postgresql.org
Subject: Re: BUG #12578: row_to_json() and to_json() add 'T' in timestamp field.
Date: Sat, 17 Jan 2015 10:59:17 -0500
Message-ID: <21765.1421510357@sss.pgh.pa.us> (raw)
In-Reply-To: <20150117095500.1983.35606@wrigleys.postgresql.org>
References: <20150117095500.1983.35606@wrigleys.postgresql.org>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>
yoonghm@gmail.com writes:
> row_to_json and to_json replace the space between date and time.
This is not a bug; it's an intentional behavioral change. Per the
third bullet point in the 9.4 release notes:
* When converting values of type date, timestamp or timestamptz to JSON,
render the values in a format compliant with ISO 8601 (Andrew Dunstan)
Previously such values were rendered according to the current DateStyle
setting; but many JSON processors require timestamps to be in ISO 8601
format. If necessary, the previous behavior can be obtained by
explicitly casting the datetime value to text before passing it to the
JSON conversion function.
regards, tom lane
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: tgl@sss.pgh.pa.us, yoonghm@gmail.com
Subject: Re: BUG #12578: row_to_json() and to_json() add 'T' in timestamp field.
In-Reply-To: <21765.1421510357@sss.pgh.pa.us>
References: <20150117095500.1983.35606@wrigleys.postgresql.org> <21765.1421510357@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox