Postgresql likes Tuesday...

From: Rod Taylor <rbt(at)rbt(dot)ca>
To: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Postgresql likes Tuesday...
Date: 2002-09-30 21:37:47
Message-ID: 1033421868.66248.62.camel@jester
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

select to_char(
to_date(
CAST(extract(week from CURRENT_TIMESTAMP) as text)
|| CAST(extract(year from CURRENT_TIMESTAMP) as text)
, 'WWYYYY')
, 'FMDay, D');

to_char
------------
Tuesday, 3
(1 row)

Not that it matters for me at the moment (I care that it's in the week
of..), but why does it pick Tuesday?

--
Rod Taylor

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2002-09-30 21:42:46 Re: [COMMITTERS] pgsql/contrib/rserv ApplySnapshot.in CleanLog. ...
Previous Message Dan Langille 2002-09-30 21:33:23 Re: (Fwd) Re: Any Oracle 9 users? A test please...