Re: datestyle formatting

From: Michael Glaesemann <grzm(at)myrealbox(dot)com>
To: mstory(at)uchicago(dot)edu
Cc: pgsql-general(at)postgresql(dot)org General <pgsql-general(at)postgresql(dot)org>
Subject: Re: datestyle formatting
Date: 2005-01-11 06:21:17
Message-ID: 00DEF857-6399-11D9-8228-000A95C88220@myrealbox.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


On Jan 11, 2005, at 15:03, mstory(at)uchicago(dot)edu wrote:

> I need to know the day of the week for a schedule rotation algorithm
> i'm working
> on. Initially i was going to use the function for day of the year and
> week of
> the year to find the first day of the year, but it seems like it would
> be easier
> to use the postgres, dmy format and then parse the string for the day
> abbreviation. I've switched the datestyle format in the .conf file
> and used the
> set to command, but my output never reads as the example in the 7.4.6
> docs it
> always shows just the dmy standard output 10-12-1999 for example as
> opposed to
> wed oct 17 1987, any help on this would be appreciated

Check out to_char(). It'll probably help you get to where you want to
go.

<http://www.postgresql.org/docs/7.4/interactive/functions-
formatting.html>

Michael Glaesemann
grzm myrealbox com

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Michael Fuhr 2005-01-11 08:37:04 Re: datestyle formatting
Previous Message Tom Lane 2005-01-11 06:17:09 Re: datestyle formatting