Re: "Mons" in JDBC driver - Mailing list pgsql-jdbc

From Richard Broersma
Subject Re: "Mons" in JDBC driver
Date
Msg-id AANLkTinWbwwj2OcLfbkXcGK0u5ZqfPQ=anX_MxDRkJjG@mail.gmail.com
Whole thread Raw
In response to Re: "Mons" in JDBC driver  (Kris Jurka <books@ejurka.com>)
Responses Re: "Mons" in JDBC driver  (Kris Jurka <books@ejurka.com>)
List pgsql-jdbc
On Mon, Aug 2, 2010 at 10:23 AM, Kris Jurka <books@ejurka.com> wrote:

> Yes, this mirrors the server's behavior:
>
> kjurka=# select '3 months'::interval;
>  interval
> ----------
>  3 mons
> (1 row)


From:
http://www.postgresql.org/docs/9.0/static/runtime-config-client.html#GUC-INTERVALSTYLE

Here is what I see from the server:

p2082849b=> SET SESSION IntervalStyle TO DEFAULT;
SET
p2082849b=> select Interval '3 months';
 interval
----------
 3 mons
(1 row)

p2082849b=> SET session IntervalStyle TO 'postgres';
SET
p2082849b=> select Interval '3 months';
 interval
----------
 3 mons
(1 row)

p2082849b=> SET session IntervalStyle TO 'postgres_verbose';
SET
p2082849b=> select Interval '3 months';
 interval
----------
 @ 3 mons
(1 row)

p2082849b=> SET session IntervalStyle TO 'sql_standard';
SET
p2082849b=> select Interval '3 months';
 interval
----------
 0-3
(1 row)

p2082849b=> SET session IntervalStyle TO 'iso_8601';
SET
p2082849b=> select Interval '3 months';
 interval
----------
 P3M
(1 row)


--
Regards,
Richard Broersma Jr.

Visit the Los Angeles PostgreSQL Users Group (LAPUG)
http://pugs.postgresql.org/lapug

pgsql-jdbc by date:

Previous
From: Kris Jurka
Date:
Subject: Re: "Mons" in JDBC driver
Next
From: Kris Jurka
Date:
Subject: Re: "Mons" in JDBC driver