Re: BUG #7804: timeofday() output string is not compatible with "timestamp with time zone" data type

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: dotbrat(at)gmail(dot)com
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #7804: timeofday() output string is not compatible with "timestamp with time zone" data type
Date: 2013-01-14 18:13:32
Message-ID: 25029.1358187212@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

dotbrat(at)gmail(dot)com writes:
> SET TIME ZONE 'Europe/Minsk';
> select timeofday()::timestamp with time zone;
> ERROR: invalid input syntax for type timestamp with time zone: "Mon Jan 14
> 08:18:20.333915 2013 FET"

The issue seems to be that the recently-invented abbreviation FET
isn't anywhere in our default list of timezone abbreviations.

That probably should be fixed, but in the meantime, you really should be
aware that timeofday() is deprecated, and there's no reason at all to
use it in the above manner anyway. now() or current_timestamp are
simpler and much faster.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Руслан Измайлов 2013-01-14 18:38:29 Re: BUG #7804: timeofday() output string is not compatible with "timestamp with time zone" data type
Previous Message Heikki Linnakangas 2013-01-14 18:12:37 Re: BUG #7805: Inconsistency, multiple versions