Bad timestamp external representation 'Sun 05 May 11:53:44.731416 2002 EEST'

From: Vladimir Zolotykh <gsmith(at)eurocom(dot)od(dot)ua>
To: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Bad timestamp external representation 'Sun 05 May 11:53:44.731416 2002 EEST'
Date: 2002-05-05 09:06:59
Message-ID: 3CD4F633.7137A917@eurocom.od.ua
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi

I found a strange error (at least at first glance I had thought it
seems so):

mail=# select * from accounts_log where login='trading';
id | login | debet | credit | when
------+---------+-------+-----------+------------------------------
6289 | trading | 1170 | 1294.9071 | Wed 21 Mar 18:07:19 2001 EET
(1 row)

mail=# select * from accounts_log where login='trading' and "when" = '2001-03-21 18:07:19';
id | login | debet | credit | when
------+---------+-------+-----------+------------------------------
6289 | trading | 1170 | 1294.9071 | Wed 21 Mar 18:07:19 2001 EET
(1 row)

mail=# select * from accounts_log where login='trading' and "when" >= '2001-03-21 18:07:19';
ERROR: Bad timestamp external representation 'Wed 04 Apr 20:00:56 2001 EEST'
mail=#

Could you add some comments to this ?

Also I'd like to question if you don't mind: While now() outputs

Sun 05 May 11:53:44.731416 2002 EEST

It seems I can't use EEST (Eastern Europe Summer Time) in input:

proba=# select * from temp;
n | date
---+------
(0 rows)

proba=# \d temp
Table "temp"
Column | Type | Modifiers
--------+--------------------------+-----------
n | integer |
date | timestamp with time zone |

proba=# select * from temp where date = 'Sun 05 May 11:53:44.731416 2002 EEST';
ERROR: Bad timestamp external representation 'Sun 05 May 11:53:44.731416 2002 EEST'
proba=#

The EETDST time zone abbreviation works but it is inconvenient because
all files produced with pg_dump utility or copy command contains EEST
and I can't use then without some modifications e.g

$ psql -e -f copy-command.sql proba
Using pager is off.
COPY "temp" FROM stdin;
psql:copy-command.sql:1: ERROR: copy: line 2952, Bad timestamp external representation 'Mon 26 Mar 18:45:36 2001
EEST'
psql:copy-command.sql:1: lost synchronization with server, resetting connection
$

To be precise, DST time was started at 25 Mar 2001 at 01:00 UTC for
our time zone (UTC+2) if it does matter.

Could you suggest something ?

Using PostgreSQL 7.2 on Slackware 8.0

Best regards

--
Vladimir Zolotykh

Browse pgsql-hackers by date

  From Date Subject
Next Message mlw 2002-05-05 14:01:57 Musings
Previous Message Jean-Michel POURE 2002-05-05 08:53:03 Re: Execution time of UPDATE raises dramatically!