Fix abstime-to-time cast function, which has had broken implementation
authorTom Lane <tgl@sss.pgh.pa.us>
Thu, 17 Apr 2003 04:50:35 +0000 (04:50 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Thu, 17 Apr 2003 04:50:35 +0000 (04:50 +0000)
since 7.2, per bug #947.  Turns out it had wrong volatility label, too.
Can't force initdb in 7.3 branch, but fix anyway for future installs.

src/include/catalog/pg_proc.h

index 6a86dce88883a0ed94747d43e836d6176c11675b..2ddfa44501a8734cea46bb2625d207e7a8bee338 100644 (file)
@@ -7,7 +7,7 @@
  * Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
  * Portions Copyright (c) 1994, Regents of the University of California
  *
- * $Id: pg_proc.h,v 1.275.2.1 2003/03/14 04:44:05 tgl Exp $
+ * $Id: pg_proc.h,v 1.275.2.2 2003/04/17 04:50:35 tgl Exp $
  *
  * NOTES
  *       The script catalog/genbki.sh reads this file and generates .bki
@@ -1679,7 +1679,7 @@ DESCR("less-equal-greater");
 DATA(insert OID = 1359 (  timestamptz     PGNSP PGUID 12 f f t f i 2 1184 "1082 1266"  datetimetz_timestamptz - _null_ ));
 DESCR("convert date and time with time zone to timestamp with time zone");
 
-DATA(insert OID = 1364 (  time                    PGNSP PGUID 14 f f t f i 1 1083 "702"  "select time(cast($1 as timestamp without time zone))" - _null_ ));
+DATA(insert OID = 1364 (  time                    PGNSP PGUID 14 f f t f s 1 1083 "702"  "select cast(cast($1 as timestamp without time zone) as time)" - _null_ ));
 DESCR("convert abstime to time");
 
 DATA(insert OID = 1367 (  character_length     PGNSP PGUID 12 f f t f i 1      23 "1042"  bpcharlen - _null_ ));