Re: to_date() confusion - Mailing list pgsql-sql

From Bruno Wolff III
Subject Re: to_date() confusion
Date
Msg-id 20030108150603.GB27870@wolff.to
Whole thread Raw
In response to to_date() confusion  (Richard Rowell <richard@bowmansystems.com>)
List pgsql-sql
On Wed, Jan 08, 2003 at 08:49:00 -0600, Richard Rowell <richard@bowmansystems.com> wrote:
> I'm confused.  How do I massage the integer 10102 into the date
> 2002-01-01?
> 
> cmi=> select to_char(10102,'000000');
>  to_char 
> ---------
>   010102
> (1 row)

Note the leading space in the returned row. That is probably what is making
the difference.  You probably want to use to_char(10102,'FM000000').


pgsql-sql by date:

Previous
From: Richard Rowell
Date:
Subject: to_date() confusion
Next
From: "Rajesh Kumar Mallah."
Date:
Subject: Re: Search and Replace