converting varchar date strings to date

From: "pw" <p(dot)willis(at)telus(dot)net>
To: <pgsql-general(at)postgresql(dot)org>
Subject: converting varchar date strings to date
Date: 2003-10-14 16:54:44
Message-ID: 001001c39273$de6e70e0$0f01a8c0@peter
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hello,

How can I typecast a date generated from VARCHAR fields into
a date field

ie:

UPDATE inventory SET date_field = vc_year||'-'||vc_month||'-'||vc_day;

where the date string is built up from varchar fields?

Thanks for any help.

Peter

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Mike Mascari 2003-10-14 16:59:01 Re: SET within a function?
Previous Message Edmund Dengler 2003-10-14 16:48:17 Re: SET within a function?