how to cast this ?

From: juerg(dot)rietmann(at)pup(dot)ch
To: pgsql-sql(at)postgresql(dot)org
Subject: how to cast this ?
Date: 2002-09-12 09:22:35
Message-ID: OF44E0446D.F551C2BF-ONC1256C32.00331D16-C1256C32.003397BB@pup.ch
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Hello there

I have a db table with two char fields :

log_date char(10)
log_time char(8)

I added a new field log_timestamp of type timestamptz

How do I take the data from log_date and log_time and put it into
log_timestamp ?

update log set log_timestamp = cast (log_date as timestamp) || cast
(log_time as timestamp)

is not working.

Thank's in advance ... jr

__________________________________________________

PFISTER + PARTNER, SYSTEM - ENGINEERING AG
Juerg Rietmann
Grundstrasse 22a
6343 Rotkreuz
Switzerland

internet : www.pup.ch
phone : +4141 790 4040
fax : +4141 790 2545
mobile : +4179 211 0315
__________________________________________________

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Oliver Elphick 2002-09-12 09:45:54 Re: how to cast this ?
Previous Message Rudi Starcevic 2002-09-12 05:41:24 htdig & postgresql