Migrating from 7.1 to 7.2 - Mailing list pgsql-sql

From Edipo Elder Fernandes de Melo
Subject Migrating from 7.1 to 7.2
Date
Msg-id 20020508204834.53EEC475EB0@postgresql.org
Whole thread Raw
Responses Re: Migrating from 7.1 to 7.2
List pgsql-sql
Hello, 
   I wrote a plpgsql procedure that returns the executition time of it, 
like this: 

create procedure myProc() returns time as ' 
declare    v_start time;    v_end time; 
begin    select timeofday()::timestamp::time into v_start;    (do some work)    select timeofday()::timestamp::time
intov_end;    return v_end - v_start; 
 
end;' language 'plpgsql' 
   This worked fine at 7.1, but now, in 7.2.1, isn't working. In 7.1, i 
got: 

template1=# select timeofday()::time; 
ERROR:  Bad time external representation 'Wed May 08 17:19:15.389569 2002 
BRT' 
template1=# select timeofday()::timestamp::time; ?column? 
---------- 17:19:20 
(1 row) 
   In 7.2.1, i got: 

bench=# select timeofday()::time; 
ERROR:  Bad time external representation 'Wed May 08 17:20:37.891559 2002 
BRT' 
bench=# select timeofday()::timestamp::time; 
ERROR:  Cannot cast type 'timestamp with time zone' to 'time without time 
zone' 
   I tried change time zones, date style, etc... but I didn't fix it. 
   Thanks for any help, 
   Edipo Elder    [edipoelder@ig.com.br] 

_________________________________________________________________________
Voc� podia estar baixando sua musica predileta, enquanto lia esse e-mail.
N�o perca tempo, tenha acesso r�pido a internet com o Super iG.
http://registro.ig.com.br/superig



pgsql-sql by date:

Previous
From: Mike Diehl
Date:
Subject: having trouble w/ having clause...
Next
From: Tom Lane
Date:
Subject: Re: Performance on update from join