Index: src/backend/utils/adt/timestamp.c
===================================================================
RCS file: /projects/cvsroot/pgsql/src/backend/utils/adt/timestamp.c,v
retrieving revision 1.165
diff -c -r1.165 timestamp.c
*** src/backend/utils/adt/timestamp.c	13 Jul 2006 16:49:16 -0000	1.165
--- src/backend/utils/adt/timestamp.c	29 Aug 2006 14:42:27 -0000
***************
*** 2494,2500 ****
  	float8		factor = PG_GETARG_FLOAT8(1);
  	double		month_remainder,
  				day_remainder,
! 				month_remainder_days;
  	Interval   *result;
  
  	result = (Interval *) palloc(sizeof(Interval));
--- 2494,2502 ----
  	float8		factor = PG_GETARG_FLOAT8(1);
  	double		month_remainder,
  				day_remainder,
! 				month_remainder_days,
! 				month_remainder_day_frac,
! 				month_remainder_time;
  	Interval   *result;
  
  	result = (Interval *) palloc(sizeof(Interval));
***************
*** 2519,2526 ****
  	/* fractional months full days into days */
  	month_remainder_days = month_remainder * DAYS_PER_MONTH;
  	result->day += (int32) month_remainder_days;
! 	/* fractional months partial days into time */
! 	day_remainder += month_remainder_days - (int32) month_remainder_days;
  
  #ifdef HAVE_INT64_TIMESTAMP
  	result->time = rint(span->time * factor + day_remainder * USECS_PER_DAY);
--- 2521,2561 ----
  	/* fractional months full days into days */
  	month_remainder_days = month_remainder * DAYS_PER_MONTH;
  	result->day += (int32) month_remainder_days;
! 
!     /*
!      * Add to result->day any fractional days from the month component that 
!      * round to 24 hour periods after being converted to time.
!      */
! 
!     month_remainder_day_frac = month_remainder_days 
!                                             - (int32) month_remainder_days;
! 
! #ifdef HAVE_INT64_TIMESTAMP
!     month_remainder_time = month_remainder_day_frac * USECS_PER_DAY;
! 	if (rint(month_remainder_time) == USECS_PER_DAY)
! 	{
! 	   result->day++;
! 	}
! 	else if (rint(month_remainder_time) == -USECS_PER_DAY)
! 	{
! 	   result->day--;
! 	}
! #else
!     month_remainder_time = month_remainder_day_frac * SECS_PER_DAY;
! 	if (TSROUND(month_remainder_time) == SECS_PER_DAY)
! 	{
! 	   result->day++;
! 	}
! 	else if (TSROUND(month_remainder_time) == -SECS_PER_DAY)
! 	{
! 	   result->day--;
! 	}
! #endif
! 	else
! 	{
!     	/* fractional months partial days into time */
!     	day_remainder += month_remainder_day_frac;
! 	}
  
  #ifdef HAVE_INT64_TIMESTAMP
  	result->time = rint(span->time * factor + day_remainder * USECS_PER_DAY);
***************
*** 2548,2558 ****
  	float8		factor = PG_GETARG_FLOAT8(1);
  	double		month_remainder,
  				day_remainder,
! 				month_remainder_days;
  	Interval   *result;
  
  	result = (Interval *) palloc(sizeof(Interval));
  
  	if (factor == 0.0)
  		ereport(ERROR,
  				(errcode(ERRCODE_DIVISION_BY_ZERO),
--- 2583,2601 ----
  	float8		factor = PG_GETARG_FLOAT8(1);
  	double		month_remainder,
  				day_remainder,
! 				month_remainder_days,
! 				month_remainder_day_frac,
! 				month_remainder_time;
  	Interval   *result;
  
  	result = (Interval *) palloc(sizeof(Interval));
  
+     /*
+         a: (fl) select '41 mon'::interval / 10;
+         *span = { time = 0., day = 0, month = 41 }
+         factor = 10.
+      */
+ 
  	if (factor == 0.0)
  		ereport(ERROR,
  				(errcode(ERRCODE_DIVISION_BY_ZERO),
***************
*** 2565,2579 ****
  	month_remainder -= result->month;
  	day_remainder -= result->day;
  
! 	/*
! 	 * Handle any fractional parts the same way as in interval_mul.
! 	 */
  
  	/* fractional months full days into days */
  	month_remainder_days = month_remainder * DAYS_PER_MONTH;
  	result->day += (int32) month_remainder_days;
! 	/* fractional months partial days into time */
! 	day_remainder += month_remainder_days - (int32) month_remainder_days;
  
  #ifdef HAVE_INT64_TIMESTAMP
  	result->time = rint(span->time / factor + day_remainder * USECS_PER_DAY);
--- 2608,2652 ----
  	month_remainder -= result->month;
  	day_remainder -= result->day;
  
!     /*
!      * See note in interval_mul concerning the handling of fractional parts
!      * of the month and day quotients.
!      */
  
  	/* fractional months full days into days */
  	month_remainder_days = month_remainder * DAYS_PER_MONTH;
  	result->day += (int32) month_remainder_days;
! 
!     /* Handle any fractional parts the same way as in interval_mul. */
!     month_remainder_day_frac = month_remainder_days 
!                                             - (int32) month_remainder_days;
! 
! #ifdef HAVE_INT64_TIMESTAMP
!     month_remainder_time = month_remainder_day_frac * USECS_PER_DAY;
! 	if (rint(month_remainder_time) == USECS_PER_DAY)
! 	{
! 	   result->day++;
! 	}
! 	else if (rint(month_remainder_time) == -USECS_PER_DAY)
! 	{
! 	   result->day--;
! 	}
! #else
!     month_remainder_time = month_remainder_day_frac * SECS_PER_DAY;
! 	if (TSROUND(month_remainder_time) == SECS_PER_DAY)
! 	{
! 	   result->day++;
! 	}
! 	else if (TSROUND(month_remainder_time) == -SECS_PER_DAY)
! 	{
! 	   result->day--;
! 	}
! #endif
! 	else
! 	{
!     	/* fractional months partial days into time */
!     	day_remainder += month_remainder_day_frac;
! 	}
  
  #ifdef HAVE_INT64_TIMESTAMP
  	result->time = rint(span->time / factor + day_remainder * USECS_PER_DAY);
Index: src/test/regress/expected/horology.out
===================================================================
RCS file: /projects/cvsroot/pgsql/src/test/regress/expected/horology.out,v
retrieving revision 1.62
diff -c -r1.62 horology.out
*** src/test/regress/expected/horology.out	25 Jul 2006 03:51:22 -0000	1.62
--- src/test/regress/expected/horology.out	29 Aug 2006 14:42:36 -0000
***************
*** 873,882 ****
   07:31:00
  (1 row)
  
! SELECT t.d1 + i.f1 AS "102" FROM TIMESTAMP_TBL t, INTERVAL_TBL i
    WHERE t.d1 BETWEEN '1990-01-01' AND '2001-01-01'
      AND i.f1 BETWEEN '00:00' AND '23:00';
!              102             
  -----------------------------
   Mon Feb 10 17:33:01 1997
   Mon Feb 10 22:32:01 1997
--- 873,882 ----
   07:31:00
  (1 row)
  
! SELECT t.d1 + i.f1 AS "104" FROM TIMESTAMP_TBL t, INTERVAL_TBL i
    WHERE t.d1 BETWEEN '1990-01-01' AND '2001-01-01'
      AND i.f1 BETWEEN '00:00' AND '23:00';
!              104             
  -----------------------------
   Mon Feb 10 17:33:01 1997
   Mon Feb 10 22:32:01 1997
***************
*** 984,993 ****
   Sun Dec 31 22:32:01 2000
  (104 rows)
  
! SELECT t.d1 - i.f1 AS "102" FROM TIMESTAMP_TBL t, INTERVAL_TBL i
    WHERE t.d1 BETWEEN '1990-01-01' AND '2001-01-01'
      AND i.f1 BETWEEN '00:00' AND '23:00';
!              102             
  -----------------------------
   Mon Feb 10 17:31:01 1997
   Mon Feb 10 12:32:01 1997
--- 984,993 ----
   Sun Dec 31 22:32:01 2000
  (104 rows)
  
! SELECT t.d1 - i.f1 AS "104" FROM TIMESTAMP_TBL t, INTERVAL_TBL i
    WHERE t.d1 BETWEEN '1990-01-01' AND '2001-01-01'
      AND i.f1 BETWEEN '00:00' AND '23:00';
!              104             
  -----------------------------
   Mon Feb 10 17:31:01 1997
   Mon Feb 10 12:32:01 1997
***************
*** 1095,1102 ****
   Sun Dec 31 12:32:01 2000
  (104 rows)
  
! SELECT t.f1 + i.f1 AS "80" FROM TIME_TBL t, INTERVAL_TBL i;
!      80      
  -------------
   00:01:00
   05:00:00
--- 1095,1102 ----
   Sun Dec 31 12:32:01 2000
  (104 rows)
  
! SELECT t.f1 + i.f1 AS "150" FROM TIME_TBL t, INTERVAL_TBL i;
!      150     
  -------------
   00:01:00
   05:00:00
***************
*** 1108,1113 ****
--- 1108,1118 ----
   00:00:00
   00:00:00
   12:00:00
+  00:00:00
+  00:00:00
+  00:00:00
+  00:00:00
+  00:00:00
   01:01:00
   06:00:00
   01:00:00
***************
*** 1118,1123 ****
--- 1123,1133 ----
   01:00:00
   01:00:00
   13:00:00
+  01:00:00
+  01:00:00
+  01:00:00
+  01:00:00
+  01:00:00
   02:04:00
   07:03:00
   02:03:00
***************
*** 1128,1133 ****
--- 1138,1148 ----
   02:03:00
   02:03:00
   14:03:00
+  02:03:00
+  02:03:00
+  02:03:00
+  02:03:00
+  02:03:00
   12:00:00
   16:59:00
   11:59:00
***************
*** 1138,1143 ****
--- 1153,1163 ----
   11:59:00
   11:59:00
   23:59:00
+  11:59:00
+  11:59:00
+  11:59:00
+  11:59:00
+  11:59:00
   12:01:00
   17:00:00
   12:00:00
***************
*** 1148,1153 ****
--- 1168,1178 ----
   12:00:00
   12:00:00
   00:00:00
+  12:00:00
+  12:00:00
+  12:00:00
+  12:00:00
+  12:00:00
   12:02:00
   17:01:00
   12:01:00
***************
*** 1158,1163 ****
--- 1183,1193 ----
   12:01:00
   12:01:00
   00:01:00
+  12:01:00
+  12:01:00
+  12:01:00
+  12:01:00
+  12:01:00
   00:00:00
   04:59:00
   23:59:00
***************
*** 1168,1173 ****
--- 1198,1208 ----
   23:59:00
   23:59:00
   11:59:00
+  23:59:00
+  23:59:00
+  23:59:00
+  23:59:00
+  23:59:00
   00:00:59.99
   04:59:59.99
   23:59:59.99
***************
*** 1178,1183 ****
--- 1213,1223 ----
   23:59:59.99
   23:59:59.99
   11:59:59.99
+  23:59:59.99
+  23:59:59.99
+  23:59:59.99
+  23:59:59.99
+  23:59:59.99
   15:37:39
   20:36:39
   15:36:39
***************
*** 1188,1193 ****
--- 1228,1238 ----
   15:36:39
   15:36:39
   03:36:39
+  15:36:39
+  15:36:39
+  15:36:39
+  15:36:39
+  15:36:39
   15:37:39
   20:36:39
   15:36:39
***************
*** 1198,1207 ****
   15:36:39
   15:36:39
   03:36:39
! (100 rows)
  
! SELECT t.f1 - i.f1 AS "80" FROM TIME_TBL t, INTERVAL_TBL i;
!      80      
  -------------
   23:59:00
   19:00:00
--- 1243,1257 ----
   15:36:39
   15:36:39
   03:36:39
!  15:36:39
!  15:36:39
!  15:36:39
!  15:36:39
!  15:36:39
! (150 rows)
  
! SELECT t.f1 - i.f1 AS "150" FROM TIME_TBL t, INTERVAL_TBL i;
!      150     
  -------------
   23:59:00
   19:00:00
***************
*** 1213,1218 ****
--- 1263,1273 ----
   00:00:00
   00:00:00
   12:00:00
+  00:00:00
+  00:00:00
+  00:00:00
+  00:00:00
+  00:00:00
   00:59:00
   20:00:00
   01:00:00
***************
*** 1223,1228 ****
--- 1278,1288 ----
   01:00:00
   01:00:00
   13:00:00
+  01:00:00
+  01:00:00
+  01:00:00
+  01:00:00
+  01:00:00
   02:02:00
   21:03:00
   02:03:00
***************
*** 1233,1238 ****
--- 1293,1303 ----
   02:03:00
   02:03:00
   14:03:00
+  02:03:00
+  02:03:00
+  02:03:00
+  02:03:00
+  02:03:00
   11:58:00
   06:59:00
   11:59:00
***************
*** 1244,1249 ****
--- 1309,1319 ----
   11:59:00
   23:59:00
   11:59:00
+  11:59:00
+  11:59:00
+  11:59:00
+  11:59:00
+  11:59:00
   07:00:00
   12:00:00
   12:00:00
***************
*** 1254,1259 ****
--- 1324,1334 ----
   12:00:00
   00:00:00
   12:00:00
+  12:00:00
+  12:00:00
+  12:00:00
+  12:00:00
+  12:00:00
   07:01:00
   12:01:00
   12:01:00
***************
*** 1263,1268 ****
--- 1338,1348 ----
   12:01:00
   12:01:00
   00:01:00
+  12:01:00
+  12:01:00
+  12:01:00
+  12:01:00
+  12:01:00
   23:58:00
   18:59:00
   23:59:00
***************
*** 1273,1278 ****
--- 1353,1363 ----
   23:59:00
   23:59:00
   11:59:00
+  23:59:00
+  23:59:00
+  23:59:00
+  23:59:00
+  23:59:00
   23:58:59.99
   18:59:59.99
   23:59:59.99
***************
*** 1283,1288 ****
--- 1368,1378 ----
   23:59:59.99
   23:59:59.99
   11:59:59.99
+  23:59:59.99
+  23:59:59.99
+  23:59:59.99
+  23:59:59.99
+  23:59:59.99
   15:35:39
   10:36:39
   15:36:39
***************
*** 1293,1298 ****
--- 1383,1393 ----
   15:36:39
   15:36:39
   03:36:39
+  15:36:39
+  15:36:39
+  15:36:39
+  15:36:39
+  15:36:39
   15:35:39
   10:36:39
   15:36:39
***************
*** 1303,1312 ****
   15:36:39
   15:36:39
   03:36:39
! (100 rows)
  
! SELECT t.f1 + i.f1 AS "100" FROM TIMETZ_TBL t, INTERVAL_TBL i;
!       100       
  ----------------
   00:02:00-07
   05:01:00-07
--- 1398,1412 ----
   15:36:39
   15:36:39
   03:36:39
!  15:36:39
!  15:36:39
!  15:36:39
!  15:36:39
!  15:36:39
! (150 rows)
  
! SELECT t.f1 + i.f1 AS "180" FROM TIMETZ_TBL t, INTERVAL_TBL i;
!       180       
  ----------------
   00:02:00-07
   05:01:00-07
***************
*** 1318,1323 ****
--- 1418,1428 ----
   00:01:00-07
   00:01:00-07
   12:01:00-07
+  00:01:00-07
+  00:01:00-07
+  00:01:00-07
+  00:01:00-07
+  00:01:00-07
   01:01:00-07
   06:00:00-07
   01:00:00-07
***************
*** 1328,1333 ****
--- 1433,1443 ----
   01:00:00-07
   01:00:00-07
   13:00:00-07
+  01:00:00-07
+  01:00:00-07
+  01:00:00-07
+  01:00:00-07
+  01:00:00-07
   02:04:00-07
   07:03:00-07
   02:03:00-07
***************
*** 1338,1343 ****
--- 1448,1458 ----
   02:03:00-07
   02:03:00-07
   14:03:00-07
+  02:03:00-07
+  02:03:00-07
+  02:03:00-07
+  02:03:00-07
+  02:03:00-07
   07:08:00-08
   12:07:00-08
   07:07:00-08
***************
*** 1348,1353 ****
--- 1463,1473 ----
   07:07:00-08
   07:07:00-08
   19:07:00-08
+  07:07:00-08
+  07:07:00-08
+  07:07:00-08
+  07:07:00-08
+  07:07:00-08
   08:09:00-04
   13:08:00-04
   08:08:00-04
***************
*** 1358,1363 ****
--- 1478,1488 ----
   08:08:00-04
   08:08:00-04
   20:08:00-04
+  08:08:00-04
+  08:08:00-04
+  08:08:00-04
+  08:08:00-04
+  08:08:00-04
   12:00:00-07
   16:59:00-07
   11:59:00-07
***************
*** 1368,1373 ****
--- 1493,1503 ----
   11:59:00-07
   11:59:00-07
   23:59:00-07
+  11:59:00-07
+  11:59:00-07
+  11:59:00-07
+  11:59:00-07
+  11:59:00-07
   12:01:00-07
   17:00:00-07
   12:00:00-07
***************
*** 1378,1383 ****
--- 1508,1518 ----
   12:00:00-07
   12:00:00-07
   00:00:00-07
+  12:00:00-07
+  12:00:00-07
+  12:00:00-07
+  12:00:00-07
+  12:00:00-07
   12:02:00-07
   17:01:00-07
   12:01:00-07
***************
*** 1388,1393 ****
--- 1523,1533 ----
   12:01:00-07
   12:01:00-07
   00:01:00-07
+  12:01:00-07
+  12:01:00-07
+  12:01:00-07
+  12:01:00-07
+  12:01:00-07
   00:00:00-07
   04:59:00-07
   23:59:00-07
***************
*** 1398,1403 ****
--- 1538,1548 ----
   23:59:00-07
   23:59:00-07
   11:59:00-07
+  23:59:00-07
+  23:59:00-07
+  23:59:00-07
+  23:59:00-07
+  23:59:00-07
   00:00:59.99-07
   04:59:59.99-07
   23:59:59.99-07
***************
*** 1408,1413 ****
--- 1553,1563 ----
   23:59:59.99-07
   23:59:59.99-07
   11:59:59.99-07
+  23:59:59.99-07
+  23:59:59.99-07
+  23:59:59.99-07
+  23:59:59.99-07
+  23:59:59.99-07
   15:37:39-05
   20:36:39-05
   15:36:39-05
***************
*** 1418,1423 ****
--- 1568,1578 ----
   15:36:39-05
   15:36:39-05
   03:36:39-05
+  15:36:39-05
+  15:36:39-05
+  15:36:39-05
+  15:36:39-05
+  15:36:39-05
   15:37:39-04
   20:36:39-04
   15:36:39-04
***************
*** 1428,1437 ****
   15:36:39-04
   15:36:39-04
   03:36:39-04
! (120 rows)
  
! SELECT t.f1 - i.f1 AS "100" FROM TIMETZ_TBL t, INTERVAL_TBL i;
!       100       
  ----------------
   00:00:00-07
   19:01:00-07
--- 1583,1597 ----
   15:36:39-04
   15:36:39-04
   03:36:39-04
!  15:36:39-04
!  15:36:39-04
!  15:36:39-04
!  15:36:39-04
!  15:36:39-04
! (180 rows)
  
! SELECT t.f1 - i.f1 AS "180" FROM TIMETZ_TBL t, INTERVAL_TBL i;
!       180       
  ----------------
   00:00:00-07
   19:01:00-07
***************
*** 1443,1448 ****
--- 1603,1613 ----
   00:01:00-07
   00:01:00-07
   12:01:00-07
+  00:01:00-07
+  00:01:00-07
+  00:01:00-07
+  00:01:00-07
+  00:01:00-07
   00:59:00-07
   20:00:00-07
   01:00:00-07
***************
*** 1453,1458 ****
--- 1618,1628 ----
   01:00:00-07
   01:00:00-07
   13:00:00-07
+  01:00:00-07
+  01:00:00-07
+  01:00:00-07
+  01:00:00-07
+  01:00:00-07
   02:02:00-07
   21:03:00-07
   02:03:00-07
***************
*** 1463,1468 ****
--- 1633,1643 ----
   02:03:00-07
   02:03:00-07
   14:03:00-07
+  02:03:00-07
+  02:03:00-07
+  02:03:00-07
+  02:03:00-07
+  02:03:00-07
   07:06:00-08
   02:07:00-08
   07:07:00-08
***************
*** 1473,1478 ****
--- 1648,1658 ----
   07:07:00-08
   07:07:00-08
   19:07:00-08
+  07:07:00-08
+  07:07:00-08
+  07:07:00-08
+  07:07:00-08
+  07:07:00-08
   08:07:00-04
   03:08:00-04
   08:08:00-04
***************
*** 1483,1488 ****
--- 1663,1673 ----
   08:08:00-04
   08:08:00-04
   20:08:00-04
+  08:08:00-04
+  08:08:00-04
+  08:08:00-04
+  08:08:00-04
+  08:08:00-04
   11:58:00-07
   06:59:00-07
   11:59:00-07
***************
*** 1494,1499 ****
--- 1679,1689 ----
   11:59:00-07
   23:59:00-07
   11:59:00-07
+  11:59:00-07
+  11:59:00-07
+  11:59:00-07
+  11:59:00-07
+  11:59:00-07
   07:00:00-07
   12:00:00-07
   12:00:00-07
***************
*** 1504,1509 ****
--- 1694,1704 ----
   12:00:00-07
   00:00:00-07
   12:00:00-07
+  12:00:00-07
+  12:00:00-07
+  12:00:00-07
+  12:00:00-07
+  12:00:00-07
   07:01:00-07
   12:01:00-07
   12:01:00-07
***************
*** 1513,1518 ****
--- 1708,1718 ----
   12:01:00-07
   12:01:00-07
   00:01:00-07
+  12:01:00-07
+  12:01:00-07
+  12:01:00-07
+  12:01:00-07
+  12:01:00-07
   23:58:00-07
   18:59:00-07
   23:59:00-07
***************
*** 1523,1528 ****
--- 1723,1733 ----
   23:59:00-07
   23:59:00-07
   11:59:00-07
+  23:59:00-07
+  23:59:00-07
+  23:59:00-07
+  23:59:00-07
+  23:59:00-07
   23:58:59.99-07
   18:59:59.99-07
   23:59:59.99-07
***************
*** 1533,1538 ****
--- 1738,1748 ----
   23:59:59.99-07
   23:59:59.99-07
   11:59:59.99-07
+  23:59:59.99-07
+  23:59:59.99-07
+  23:59:59.99-07
+  23:59:59.99-07
+  23:59:59.99-07
   15:35:39-05
   10:36:39-05
   15:36:39-05
***************
*** 1543,1548 ****
--- 1753,1763 ----
   15:36:39-05
   15:36:39-05
   03:36:39-05
+  15:36:39-05
+  15:36:39-05
+  15:36:39-05
+  15:36:39-05
+  15:36:39-05
   15:35:39-04
   10:36:39-04
   15:36:39-04
***************
*** 1553,1559 ****
   15:36:39-04
   15:36:39-04
   03:36:39-04
! (120 rows)
  
  -- SQL9x OVERLAPS operator
  -- test with time zone
--- 1768,1779 ----
   15:36:39-04
   15:36:39-04
   03:36:39-04
!  15:36:39-04
!  15:36:39-04
!  15:36:39-04
!  15:36:39-04
!  15:36:39-04
! (180 rows)
  
  -- SQL9x OVERLAPS operator
  -- test with time zone
***************
*** 1703,2042 ****
      | Sat Sep 22 18:19:20 2001 PDT
  (16 rows)
  
! SELECT '' AS "160", d.f1 AS "timestamp", t.f1 AS "interval", d.f1 + t.f1 AS plus
    FROM TEMP_TIMESTAMP d, INTERVAL_TBL t
    ORDER BY plus, "timestamp", "interval";
!  160 |          timestamp           |           interval            |             plus             
! -----+------------------------------+-------------------------------+------------------------------
!      | Thu Jan 01 00:00:00 1970 PST | @ 14 secs ago                 | Wed Dec 31 23:59:46 1969 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 1 min                       | Thu Jan 01 00:01:00 1970 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 5 hours                     | Thu Jan 01 05:00:00 1970 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 1 day 2 hours 3 mins 4 secs | Fri Jan 02 02:03:04 1970 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 10 days                     | Sun Jan 11 00:00:00 1970 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 mons                      | Wed Apr 01 00:00:00 1970 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 5 mons                      | Mon Jun 01 00:00:00 1970 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 5 mons 12 hours             | Mon Jun 01 12:00:00 1970 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 6 years                     | Thu Jan 01 00:00:00 1976 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 14 secs ago                 | Wed Feb 28 17:31:47 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 1 min                       | Wed Feb 28 17:33:01 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 5 hours                     | Wed Feb 28 22:32:01 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 14 secs ago                 | Thu Feb 29 17:31:47 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 1 min                       | Thu Feb 29 17:33:01 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs | Thu Feb 29 19:35:05 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 5 hours                     | Thu Feb 29 22:32:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 14 secs ago                 | Fri Mar 01 17:31:47 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 1 min                       | Fri Mar 01 17:33:01 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs | Fri Mar 01 19:35:05 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 5 hours                     | Fri Mar 01 22:32:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs | Sat Mar 02 19:35:05 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 10 days                     | Sat Mar 09 17:32:01 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 10 days                     | Sun Mar 10 17:32:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 10 days                     | Mon Mar 11 17:32:01 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 mons                      | Tue May 28 17:32:01 1996 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 mons                      | Wed May 29 17:32:01 1996 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 mons                      | Sat Jun 01 17:32:01 1996 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 5 mons                      | Sun Jul 28 17:32:01 1996 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 5 mons 12 hours             | Mon Jul 29 05:32:01 1996 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 5 mons                      | Mon Jul 29 17:32:01 1996 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 5 mons 12 hours             | Tue Jul 30 05:32:01 1996 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 5 mons                      | Thu Aug 01 17:32:01 1996 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 5 mons 12 hours             | Fri Aug 02 05:32:01 1996 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 14 secs ago                 | Mon Dec 30 17:31:47 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 1 min                       | Mon Dec 30 17:33:01 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 5 hours                     | Mon Dec 30 22:32:01 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 14 secs ago                 | Tue Dec 31 17:31:47 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 1 min                       | Tue Dec 31 17:33:01 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs | Tue Dec 31 19:35:05 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 5 hours                     | Tue Dec 31 22:32:01 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs | Wed Jan 01 19:35:05 1997 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 10 days                     | Thu Jan 09 17:32:01 1997 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 10 days                     | Fri Jan 10 17:32:01 1997 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 mons                      | Sun Mar 30 17:32:01 1997 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 mons                      | Mon Mar 31 17:32:01 1997 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 5 mons                      | Fri May 30 17:32:01 1997 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 5 mons 12 hours             | Sat May 31 05:32:01 1997 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 5 mons                      | Sat May 31 17:32:01 1997 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 5 mons 12 hours             | Sun Jun 01 05:32:01 1997 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 14 secs ago                 | Fri Dec 31 17:31:47 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 1 min                       | Fri Dec 31 17:33:01 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 5 hours                     | Fri Dec 31 22:32:01 1999 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 14 secs ago                 | Sat Jan 01 17:31:47 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 1 min                       | Sat Jan 01 17:33:01 2000 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 1 day 2 hours 3 mins 4 secs | Sat Jan 01 19:35:05 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 5 hours                     | Sat Jan 01 22:32:01 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Sun Jan 02 19:35:05 2000 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 10 days                     | Mon Jan 10 17:32:01 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 10 days                     | Tue Jan 11 17:32:01 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 14 secs ago                 | Wed Mar 15 02:13:51 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 1 min                       | Wed Mar 15 02:15:05 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 14 secs ago                 | Wed Mar 15 03:13:50 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 1 min                       | Wed Mar 15 03:15:04 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 5 hours                     | Wed Mar 15 07:14:05 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 14 secs ago                 | Wed Mar 15 08:13:47 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 5 hours                     | Wed Mar 15 08:14:04 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 1 min                       | Wed Mar 15 08:15:01 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 14 secs ago                 | Wed Mar 15 12:13:49 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 1 min                       | Wed Mar 15 12:15:03 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 14 secs ago                 | Wed Mar 15 13:13:48 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 5 hours                     | Wed Mar 15 13:14:01 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 1 min                       | Wed Mar 15 13:15:02 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 5 hours                     | Wed Mar 15 17:14:03 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 5 hours                     | Wed Mar 15 18:14:02 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Thu Mar 16 04:17:09 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Thu Mar 16 05:17:08 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Thu Mar 16 10:17:05 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Thu Mar 16 14:17:07 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Thu Mar 16 15:17:06 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 10 days                     | Sat Mar 25 02:14:05 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 10 days                     | Sat Mar 25 03:14:04 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 10 days                     | Sat Mar 25 08:14:01 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 10 days                     | Sat Mar 25 12:14:03 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 10 days                     | Sat Mar 25 13:14:02 2000 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 mons                      | Fri Mar 31 17:32:01 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 mons                      | Sat Apr 01 17:32:01 2000 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 5 mons                      | Wed May 31 17:32:01 2000 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 5 mons 12 hours             | Thu Jun 01 05:32:01 2000 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 5 mons                      | Thu Jun 01 17:32:01 2000 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 5 mons 12 hours             | Fri Jun 02 05:32:01 2000 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 mons                      | Thu Jun 15 02:14:05 2000 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 mons                      | Thu Jun 15 03:14:04 2000 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 mons                      | Thu Jun 15 08:14:01 2000 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 mons                      | Thu Jun 15 12:14:03 2000 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 mons                      | Thu Jun 15 13:14:02 2000 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 5 mons                      | Tue Aug 15 02:14:05 2000 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 5 mons                      | Tue Aug 15 03:14:04 2000 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 5 mons                      | Tue Aug 15 08:14:01 2000 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 5 mons                      | Tue Aug 15 12:14:03 2000 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 5 mons                      | Tue Aug 15 13:14:02 2000 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 5 mons 12 hours             | Tue Aug 15 14:14:05 2000 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 5 mons 12 hours             | Tue Aug 15 15:14:04 2000 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 5 mons 12 hours             | Tue Aug 15 20:14:01 2000 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 5 mons 12 hours             | Wed Aug 16 00:14:03 2000 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 5 mons 12 hours             | Wed Aug 16 01:14:02 2000 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 14 secs ago                 | Sun Dec 31 17:31:47 2000 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 1 min                       | Sun Dec 31 17:33:01 2000 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 5 hours                     | Sun Dec 31 22:32:01 2000 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 14 secs ago                 | Mon Jan 01 17:31:47 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 1 min                       | Mon Jan 01 17:33:01 2001 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Mon Jan 01 19:35:05 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 5 hours                     | Mon Jan 01 22:32:01 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 1 day 2 hours 3 mins 4 secs | Tue Jan 02 19:35:05 2001 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 10 days                     | Wed Jan 10 17:32:01 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 10 days                     | Thu Jan 11 17:32:01 2001 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 mons                      | Sat Mar 31 17:32:01 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 mons                      | Sun Apr 01 17:32:01 2001 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 5 mons                      | Thu May 31 17:32:01 2001 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 5 mons 12 hours             | Fri Jun 01 05:32:01 2001 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 5 mons                      | Fri Jun 01 17:32:01 2001 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 5 mons 12 hours             | Sat Jun 02 05:32:01 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 14 secs ago                 | Sat Sep 22 18:19:06 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 1 min                       | Sat Sep 22 18:20:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 5 hours                     | Sat Sep 22 23:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 1 day 2 hours 3 mins 4 secs | Sun Sep 23 20:22:24 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 10 days                     | Tue Oct 02 18:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 mons                      | Sat Dec 22 18:19:20 2001 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 5 mons                      | Fri Feb 22 18:19:20 2002 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 5 mons 12 hours             | Sat Feb 23 06:19:20 2002 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 6 years                     | Thu Feb 28 17:32:01 2002 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 6 years                     | Thu Feb 28 17:32:01 2002 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 6 years                     | Fri Mar 01 17:32:01 2002 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 6 years                     | Mon Dec 30 17:32:01 2002 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 6 years                     | Tue Dec 31 17:32:01 2002 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 34 years                    | Thu Jan 01 00:00:00 2004 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 6 years                     | Sat Dec 31 17:32:01 2005 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 6 years                     | Sun Jan 01 17:32:01 2006 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 6 years                     | Wed Mar 15 02:14:05 2006 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 6 years                     | Wed Mar 15 03:14:04 2006 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 6 years                     | Wed Mar 15 08:14:01 2006 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 6 years                     | Wed Mar 15 12:14:03 2006 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 6 years                     | Wed Mar 15 13:14:02 2006 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 6 years                     | Sun Dec 31 17:32:01 2006 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 6 years                     | Mon Jan 01 17:32:01 2007 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 6 years                     | Sat Sep 22 18:19:20 2007 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 34 years                    | Thu Feb 28 17:32:01 2030 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 34 years                    | Thu Feb 28 17:32:01 2030 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 34 years                    | Fri Mar 01 17:32:01 2030 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 34 years                    | Mon Dec 30 17:32:01 2030 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 34 years                    | Tue Dec 31 17:32:01 2030 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 34 years                    | Sat Dec 31 17:32:01 2033 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 34 years                    | Sun Jan 01 17:32:01 2034 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 34 years                    | Wed Mar 15 02:14:05 2034 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 34 years                    | Wed Mar 15 03:14:04 2034 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 34 years                    | Wed Mar 15 08:14:01 2034 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 34 years                    | Wed Mar 15 12:14:03 2034 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 34 years                    | Wed Mar 15 13:14:02 2034 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 34 years                    | Sun Dec 31 17:32:01 2034 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 34 years                    | Mon Jan 01 17:32:01 2035 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 34 years                    | Sat Sep 22 18:19:20 2035 PDT
! (160 rows)
  
! SELECT '' AS "160", d.f1 AS "timestamp", t.f1 AS "interval", d.f1 - t.f1 AS minus
    FROM TEMP_TIMESTAMP d, INTERVAL_TBL t
    WHERE isfinite(d.f1)
    ORDER BY minus, "timestamp", "interval";
!  160 |          timestamp           |           interval            |            minus             
! -----+------------------------------+-------------------------------+------------------------------
!      | Thu Jan 01 00:00:00 1970 PST | @ 34 years                    | Wed Jan 01 00:00:00 1936 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 34 years                    | Wed Feb 28 17:32:01 1962 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 34 years                    | Wed Feb 28 17:32:01 1962 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 34 years                    | Thu Mar 01 17:32:01 1962 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 34 years                    | Sun Dec 30 17:32:01 1962 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 34 years                    | Mon Dec 31 17:32:01 1962 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 6 years                     | Wed Jan 01 00:00:00 1964 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 34 years                    | Fri Dec 31 17:32:01 1965 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 34 years                    | Sat Jan 01 17:32:01 1966 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 34 years                    | Tue Mar 15 02:14:05 1966 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 34 years                    | Tue Mar 15 03:14:04 1966 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 34 years                    | Tue Mar 15 08:14:01 1966 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 34 years                    | Tue Mar 15 12:14:03 1966 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 34 years                    | Tue Mar 15 13:14:02 1966 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 34 years                    | Sat Dec 31 17:32:01 1966 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 34 years                    | Sun Jan 01 17:32:01 1967 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 34 years                    | Fri Sep 22 18:19:20 1967 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 5 mons 12 hours             | Thu Jul 31 12:00:00 1969 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 5 mons                      | Fri Aug 01 00:00:00 1969 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 mons                      | Wed Oct 01 00:00:00 1969 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 10 days                     | Mon Dec 22 00:00:00 1969 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 1 day 2 hours 3 mins 4 secs | Tue Dec 30 21:56:56 1969 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 5 hours                     | Wed Dec 31 19:00:00 1969 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 1 min                       | Wed Dec 31 23:59:00 1969 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 14 secs ago                 | Thu Jan 01 00:00:14 1970 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 6 years                     | Wed Feb 28 17:32:01 1990 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 6 years                     | Wed Feb 28 17:32:01 1990 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 6 years                     | Thu Mar 01 17:32:01 1990 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 6 years                     | Sun Dec 30 17:32:01 1990 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 6 years                     | Mon Dec 31 17:32:01 1990 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 6 years                     | Fri Dec 31 17:32:01 1993 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 6 years                     | Sat Jan 01 17:32:01 1994 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 6 years                     | Tue Mar 15 02:14:05 1994 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 6 years                     | Tue Mar 15 03:14:04 1994 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 6 years                     | Tue Mar 15 08:14:01 1994 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 6 years                     | Tue Mar 15 12:14:03 1994 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 6 years                     | Tue Mar 15 13:14:02 1994 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 6 years                     | Sat Dec 31 17:32:01 1994 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 6 years                     | Sun Jan 01 17:32:01 1995 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 6 years                     | Fri Sep 22 18:19:20 1995 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 5 mons 12 hours             | Thu Sep 28 05:32:01 1995 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 5 mons                      | Thu Sep 28 17:32:01 1995 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 5 mons 12 hours             | Fri Sep 29 05:32:01 1995 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 5 mons                      | Fri Sep 29 17:32:01 1995 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 5 mons 12 hours             | Sun Oct 01 05:32:01 1995 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 5 mons                      | Sun Oct 01 17:32:01 1995 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 mons                      | Tue Nov 28 17:32:01 1995 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 mons                      | Wed Nov 29 17:32:01 1995 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 mons                      | Fri Dec 01 17:32:01 1995 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 10 days                     | Sun Feb 18 17:32:01 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 10 days                     | Mon Feb 19 17:32:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 10 days                     | Tue Feb 20 17:32:01 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs | Tue Feb 27 15:28:57 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 5 hours                     | Wed Feb 28 12:32:01 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs | Wed Feb 28 15:28:57 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 1 min                       | Wed Feb 28 17:31:01 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 14 secs ago                 | Wed Feb 28 17:32:15 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 5 hours                     | Thu Feb 29 12:32:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs | Thu Feb 29 15:28:57 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 1 min                       | Thu Feb 29 17:31:01 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 14 secs ago                 | Thu Feb 29 17:32:15 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 5 hours                     | Fri Mar 01 12:32:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 1 min                       | Fri Mar 01 17:31:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 14 secs ago                 | Fri Mar 01 17:32:15 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 5 mons 12 hours             | Tue Jul 30 05:32:01 1996 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 5 mons                      | Tue Jul 30 17:32:01 1996 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 5 mons 12 hours             | Wed Jul 31 05:32:01 1996 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 5 mons                      | Wed Jul 31 17:32:01 1996 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 mons                      | Mon Sep 30 17:32:01 1996 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 mons                      | Mon Sep 30 17:32:01 1996 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 10 days                     | Fri Dec 20 17:32:01 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 10 days                     | Sat Dec 21 17:32:01 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs | Sun Dec 29 15:28:57 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 5 hours                     | Mon Dec 30 12:32:01 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs | Mon Dec 30 15:28:57 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 1 min                       | Mon Dec 30 17:31:01 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 14 secs ago                 | Mon Dec 30 17:32:15 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 5 hours                     | Tue Dec 31 12:32:01 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 1 min                       | Tue Dec 31 17:31:01 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 14 secs ago                 | Tue Dec 31 17:32:15 1996 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 5 mons 12 hours             | Sat Jul 31 05:32:01 1999 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 5 mons                      | Sat Jul 31 17:32:01 1999 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 5 mons 12 hours             | Sun Aug 01 05:32:01 1999 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 5 mons                      | Sun Aug 01 17:32:01 1999 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 mons                      | Thu Sep 30 17:32:01 1999 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 mons                      | Fri Oct 01 17:32:01 1999 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 5 mons 12 hours             | Thu Oct 14 14:14:05 1999 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 5 mons 12 hours             | Thu Oct 14 15:14:04 1999 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 5 mons 12 hours             | Thu Oct 14 20:14:01 1999 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 5 mons 12 hours             | Fri Oct 15 00:14:03 1999 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 5 mons 12 hours             | Fri Oct 15 01:14:02 1999 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 5 mons                      | Fri Oct 15 02:14:05 1999 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 5 mons                      | Fri Oct 15 03:14:04 1999 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 5 mons                      | Fri Oct 15 08:14:01 1999 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 5 mons                      | Fri Oct 15 12:14:03 1999 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 5 mons                      | Fri Oct 15 13:14:02 1999 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 mons                      | Wed Dec 15 02:14:05 1999 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 mons                      | Wed Dec 15 03:14:04 1999 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 mons                      | Wed Dec 15 08:14:01 1999 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 mons                      | Wed Dec 15 12:14:03 1999 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 mons                      | Wed Dec 15 13:14:02 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 10 days                     | Tue Dec 21 17:32:01 1999 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 10 days                     | Wed Dec 22 17:32:01 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 1 day 2 hours 3 mins 4 secs | Thu Dec 30 15:28:57 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 5 hours                     | Fri Dec 31 12:32:01 1999 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Fri Dec 31 15:28:57 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 1 min                       | Fri Dec 31 17:31:01 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 14 secs ago                 | Fri Dec 31 17:32:15 1999 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 5 hours                     | Sat Jan 01 12:32:01 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 1 min                       | Sat Jan 01 17:31:01 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 14 secs ago                 | Sat Jan 01 17:32:15 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 10 days                     | Sun Mar 05 02:14:05 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 10 days                     | Sun Mar 05 03:14:04 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 10 days                     | Sun Mar 05 08:14:01 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 10 days                     | Sun Mar 05 12:14:03 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 10 days                     | Sun Mar 05 13:14:02 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Tue Mar 14 00:11:01 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Tue Mar 14 01:11:00 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Tue Mar 14 06:10:57 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Tue Mar 14 10:10:59 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Tue Mar 14 11:10:58 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 5 hours                     | Tue Mar 14 21:14:05 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 5 hours                     | Tue Mar 14 22:14:04 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 1 min                       | Wed Mar 15 02:13:05 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 14 secs ago                 | Wed Mar 15 02:14:19 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 1 min                       | Wed Mar 15 03:13:04 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 5 hours                     | Wed Mar 15 03:14:01 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 14 secs ago                 | Wed Mar 15 03:14:18 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 5 hours                     | Wed Mar 15 07:14:03 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 1 min                       | Wed Mar 15 08:13:01 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 5 hours                     | Wed Mar 15 08:14:02 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 14 secs ago                 | Wed Mar 15 08:14:15 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 1 min                       | Wed Mar 15 12:13:03 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 14 secs ago                 | Wed Mar 15 12:14:17 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 1 min                       | Wed Mar 15 13:13:02 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 14 secs ago                 | Wed Mar 15 13:14:16 2000 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 5 mons 12 hours             | Mon Jul 31 05:32:01 2000 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 5 mons                      | Mon Jul 31 17:32:01 2000 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 5 mons 12 hours             | Tue Aug 01 05:32:01 2000 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 5 mons                      | Tue Aug 01 17:32:01 2000 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 mons                      | Sat Sep 30 17:32:01 2000 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 mons                      | Sun Oct 01 17:32:01 2000 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 10 days                     | Thu Dec 21 17:32:01 2000 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 10 days                     | Fri Dec 22 17:32:01 2000 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 1 day 2 hours 3 mins 4 secs | Sat Dec 30 15:28:57 2000 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 5 hours                     | Sun Dec 31 12:32:01 2000 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 1 day 2 hours 3 mins 4 secs | Sun Dec 31 15:28:57 2000 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 1 min                       | Sun Dec 31 17:31:01 2000 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 14 secs ago                 | Sun Dec 31 17:32:15 2000 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 5 hours                     | Mon Jan 01 12:32:01 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 1 min                       | Mon Jan 01 17:31:01 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 14 secs ago                 | Mon Jan 01 17:32:15 2001 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 5 mons 12 hours             | Sun Apr 22 06:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 5 mons                      | Sun Apr 22 18:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 mons                      | Fri Jun 22 18:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 10 days                     | Wed Sep 12 18:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 1 day 2 hours 3 mins 4 secs | Fri Sep 21 16:16:16 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 5 hours                     | Sat Sep 22 13:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 1 min                       | Sat Sep 22 18:18:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 14 secs ago                 | Sat Sep 22 18:19:34 2001 PDT
! (160 rows)
  
  SELECT '' AS "16", d.f1 AS "timestamp",
     timestamp with time zone '1980-01-06 00:00 GMT' AS gpstime_zero,
--- 1923,2422 ----
      | Sat Sep 22 18:19:20 2001 PDT
  (16 rows)
  
! SELECT '' AS "240", d.f1 AS "timestamp", t.f1 AS "interval", d.f1 + t.f1 AS plus
    FROM TEMP_TIMESTAMP d, INTERVAL_TBL t
    ORDER BY plus, "timestamp", "interval";
!  240 |          timestamp           |            interval             |             plus             
! -----+------------------------------+---------------------------------+------------------------------
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 years 5 mons 360 hours ago  | Sun Jul 17 00:00:00 1966 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 years 5 mons -360 hours ago | Tue Aug 16 00:00:00 1966 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 14 secs ago                   | Wed Dec 31 23:59:46 1969 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 1 min                         | Thu Jan 01 00:01:00 1970 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 5 hours                       | Thu Jan 01 05:00:00 1970 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 1 day 2 hours 3 mins 4 secs   | Fri Jan 02 02:03:04 1970 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 10 days                       | Sun Jan 11 00:00:00 1970 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 mons                        | Wed Apr 01 00:00:00 1970 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 5 mons                        | Mon Jun 01 00:00:00 1970 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 5 mons 12 hours               | Mon Jun 01 12:00:00 1970 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 years 5 mons -360 hours     | Thu May 17 00:00:00 1973 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 years 5 mons                | Fri Jun 01 00:00:00 1973 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 years 5 mons 360 hours      | Sat Jun 16 00:00:00 1973 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 6 years                       | Thu Jan 01 00:00:00 1976 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 years 5 mons 360 hours ago  | Sun Sep 13 17:32:01 1992 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 years 5 mons 360 hours ago  | Mon Sep 14 17:32:01 1992 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 years 5 mons 360 hours ago  | Wed Sep 16 17:32:01 1992 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 years 5 mons -360 hours ago | Tue Oct 13 17:32:01 1992 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 years 5 mons -360 hours ago | Wed Oct 14 17:32:01 1992 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 years 5 mons -360 hours ago | Fri Oct 16 17:32:01 1992 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 years 5 mons 360 hours ago  | Thu Jul 15 17:32:01 1993 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 years 5 mons 360 hours ago  | Fri Jul 16 17:32:01 1993 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 years 5 mons -360 hours ago | Sat Aug 14 17:32:01 1993 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 years 5 mons -360 hours ago | Sun Aug 15 17:32:01 1993 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 14 secs ago                   | Wed Feb 28 17:31:47 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 1 min                         | Wed Feb 28 17:33:01 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 5 hours                       | Wed Feb 28 22:32:01 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 14 secs ago                   | Thu Feb 29 17:31:47 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 1 min                         | Thu Feb 29 17:33:01 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs   | Thu Feb 29 19:35:05 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 5 hours                       | Thu Feb 29 22:32:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 14 secs ago                   | Fri Mar 01 17:31:47 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 1 min                         | Fri Mar 01 17:33:01 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs   | Fri Mar 01 19:35:05 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 5 hours                       | Fri Mar 01 22:32:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs   | Sat Mar 02 19:35:05 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 10 days                       | Sat Mar 09 17:32:01 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 10 days                       | Sun Mar 10 17:32:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 10 days                       | Mon Mar 11 17:32:01 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 mons                        | Tue May 28 17:32:01 1996 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 mons                        | Wed May 29 17:32:01 1996 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 mons                        | Sat Jun 01 17:32:01 1996 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 years 5 mons 360 hours ago  | Tue Jul 16 17:32:01 1996 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 years 5 mons 360 hours ago  | Wed Jul 17 17:32:01 1996 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 5 mons                        | Sun Jul 28 17:32:01 1996 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 5 mons 12 hours               | Mon Jul 29 05:32:01 1996 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 5 mons                        | Mon Jul 29 17:32:01 1996 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 5 mons 12 hours               | Tue Jul 30 05:32:01 1996 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 5 mons                        | Thu Aug 01 17:32:01 1996 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 5 mons 12 hours               | Fri Aug 02 05:32:01 1996 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 years 5 mons -360 hours ago | Thu Aug 15 17:32:01 1996 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 years 5 mons -360 hours ago | Fri Aug 16 17:32:01 1996 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 years 5 mons 360 hours ago  | Mon Sep 30 02:14:05 1996 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 years 5 mons 360 hours ago  | Mon Sep 30 03:14:04 1996 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 years 5 mons 360 hours ago  | Mon Sep 30 08:14:01 1996 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 years 5 mons 360 hours ago  | Mon Sep 30 12:14:03 1996 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 years 5 mons 360 hours ago  | Mon Sep 30 13:14:02 1996 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 years 5 mons -360 hours ago | Wed Oct 30 01:14:05 1996 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 years 5 mons -360 hours ago | Wed Oct 30 02:14:04 1996 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 years 5 mons -360 hours ago | Wed Oct 30 07:14:01 1996 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 years 5 mons -360 hours ago | Wed Oct 30 11:14:03 1996 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 years 5 mons -360 hours ago | Wed Oct 30 12:14:02 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 14 secs ago                   | Mon Dec 30 17:31:47 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 1 min                         | Mon Dec 30 17:33:01 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 5 hours                       | Mon Dec 30 22:32:01 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 14 secs ago                   | Tue Dec 31 17:31:47 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 1 min                         | Tue Dec 31 17:33:01 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs   | Tue Dec 31 19:35:05 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 5 hours                       | Tue Dec 31 22:32:01 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs   | Wed Jan 01 19:35:05 1997 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 10 days                       | Thu Jan 09 17:32:01 1997 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 10 days                       | Fri Jan 10 17:32:01 1997 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 mons                        | Sun Mar 30 17:32:01 1997 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 mons                        | Mon Mar 31 17:32:01 1997 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 5 mons                        | Fri May 30 17:32:01 1997 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 5 mons 12 hours               | Sat May 31 05:32:01 1997 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 5 mons                        | Sat May 31 17:32:01 1997 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 5 mons 12 hours               | Sun Jun 01 05:32:01 1997 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 years 5 mons 360 hours ago  | Wed Jul 16 17:32:01 1997 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 years 5 mons 360 hours ago  | Thu Jul 17 17:32:01 1997 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 years 5 mons -360 hours ago | Fri Aug 15 17:32:01 1997 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 years 5 mons -360 hours ago | Sat Aug 16 17:32:01 1997 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 years 5 mons 360 hours ago  | Tue Apr 07 18:19:20 1998 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 years 5 mons -360 hours ago | Thu May 07 18:19:20 1998 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 years 5 mons -360 hours     | Tue Jul 13 17:32:01 1999 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 years 5 mons -360 hours     | Wed Jul 14 17:32:01 1999 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 years 5 mons -360 hours     | Sat Jul 17 17:32:01 1999 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 years 5 mons                | Wed Jul 28 17:32:01 1999 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 years 5 mons                | Thu Jul 29 17:32:01 1999 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 years 5 mons                | Sun Aug 01 17:32:01 1999 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 years 5 mons 360 hours      | Thu Aug 12 17:32:01 1999 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 years 5 mons 360 hours      | Fri Aug 13 17:32:01 1999 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 years 5 mons 360 hours      | Mon Aug 16 17:32:01 1999 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 14 secs ago                   | Fri Dec 31 17:31:47 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 1 min                         | Fri Dec 31 17:33:01 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 5 hours                       | Fri Dec 31 22:32:01 1999 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 14 secs ago                   | Sat Jan 01 17:31:47 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 1 min                         | Sat Jan 01 17:33:01 2000 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 1 day 2 hours 3 mins 4 secs   | Sat Jan 01 19:35:05 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 5 hours                       | Sat Jan 01 22:32:01 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Sun Jan 02 19:35:05 2000 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 10 days                       | Mon Jan 10 17:32:01 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 10 days                       | Tue Jan 11 17:32:01 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 14 secs ago                   | Wed Mar 15 02:13:51 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 1 min                         | Wed Mar 15 02:15:05 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 14 secs ago                   | Wed Mar 15 03:13:50 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 1 min                         | Wed Mar 15 03:15:04 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 5 hours                       | Wed Mar 15 07:14:05 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 14 secs ago                   | Wed Mar 15 08:13:47 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 5 hours                       | Wed Mar 15 08:14:04 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 1 min                         | Wed Mar 15 08:15:01 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 14 secs ago                   | Wed Mar 15 12:13:49 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 1 min                         | Wed Mar 15 12:15:03 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 14 secs ago                   | Wed Mar 15 13:13:48 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 5 hours                       | Wed Mar 15 13:14:01 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 1 min                         | Wed Mar 15 13:15:02 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 5 hours                       | Wed Mar 15 17:14:03 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 5 hours                       | Wed Mar 15 18:14:02 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Thu Mar 16 04:17:09 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Thu Mar 16 05:17:08 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Thu Mar 16 10:17:05 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Thu Mar 16 14:17:07 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Thu Mar 16 15:17:06 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 10 days                       | Sat Mar 25 02:14:05 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 10 days                       | Sat Mar 25 03:14:04 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 10 days                       | Sat Mar 25 08:14:01 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 10 days                       | Sat Mar 25 12:14:03 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 10 days                       | Sat Mar 25 13:14:02 2000 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 mons                        | Fri Mar 31 17:32:01 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 mons                        | Sat Apr 01 17:32:01 2000 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 years 5 mons -360 hours     | Mon May 15 17:32:01 2000 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 years 5 mons -360 hours     | Tue May 16 17:32:01 2000 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 years 5 mons                | Tue May 30 17:32:01 2000 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 years 5 mons                | Wed May 31 17:32:01 2000 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 5 mons                        | Wed May 31 17:32:01 2000 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 5 mons 12 hours               | Thu Jun 01 05:32:01 2000 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 5 mons                        | Thu Jun 01 17:32:01 2000 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 5 mons 12 hours               | Fri Jun 02 05:32:01 2000 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 years 5 mons 360 hours      | Wed Jun 14 17:32:01 2000 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 mons                        | Thu Jun 15 02:14:05 2000 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 mons                        | Thu Jun 15 03:14:04 2000 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 mons                        | Thu Jun 15 08:14:01 2000 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 mons                        | Thu Jun 15 12:14:03 2000 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 mons                        | Thu Jun 15 13:14:02 2000 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 years 5 mons 360 hours      | Thu Jun 15 17:32:01 2000 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 5 mons                        | Tue Aug 15 02:14:05 2000 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 5 mons                        | Tue Aug 15 03:14:04 2000 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 5 mons                        | Tue Aug 15 08:14:01 2000 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 5 mons                        | Tue Aug 15 12:14:03 2000 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 5 mons                        | Tue Aug 15 13:14:02 2000 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 5 mons 12 hours               | Tue Aug 15 14:14:05 2000 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 5 mons 12 hours               | Tue Aug 15 15:14:04 2000 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 5 mons 12 hours               | Tue Aug 15 20:14:01 2000 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 5 mons 12 hours               | Wed Aug 16 00:14:03 2000 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 5 mons 12 hours               | Wed Aug 16 01:14:02 2000 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 14 secs ago                   | Sun Dec 31 17:31:47 2000 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 1 min                         | Sun Dec 31 17:33:01 2000 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 5 hours                       | Sun Dec 31 22:32:01 2000 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 14 secs ago                   | Mon Jan 01 17:31:47 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 1 min                         | Mon Jan 01 17:33:01 2001 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Mon Jan 01 19:35:05 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 5 hours                       | Mon Jan 01 22:32:01 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 1 day 2 hours 3 mins 4 secs   | Tue Jan 02 19:35:05 2001 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 10 days                       | Wed Jan 10 17:32:01 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 10 days                       | Thu Jan 11 17:32:01 2001 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 mons                        | Sat Mar 31 17:32:01 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 mons                        | Sun Apr 01 17:32:01 2001 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 5 mons                        | Thu May 31 17:32:01 2001 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 5 mons 12 hours               | Fri Jun 01 05:32:01 2001 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 5 mons                        | Fri Jun 01 17:32:01 2001 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 5 mons 12 hours               | Sat Jun 02 05:32:01 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 14 secs ago                   | Sat Sep 22 18:19:06 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 1 min                         | Sat Sep 22 18:20:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 5 hours                       | Sat Sep 22 23:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 1 day 2 hours 3 mins 4 secs   | Sun Sep 23 20:22:24 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 10 days                       | Tue Oct 02 18:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 mons                        | Sat Dec 22 18:19:20 2001 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 5 mons                        | Fri Feb 22 18:19:20 2002 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 5 mons 12 hours               | Sat Feb 23 06:19:20 2002 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 6 years                       | Thu Feb 28 17:32:01 2002 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 6 years                       | Thu Feb 28 17:32:01 2002 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 6 years                       | Fri Mar 01 17:32:01 2002 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 6 years                       | Mon Dec 30 17:32:01 2002 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 6 years                       | Tue Dec 31 17:32:01 2002 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 years 5 mons -360 hours     | Fri May 16 17:32:01 2003 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 years 5 mons -360 hours     | Sat May 17 17:32:01 2003 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 years 5 mons                | Sat May 31 17:32:01 2003 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 years 5 mons                | Sun Jun 01 17:32:01 2003 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 years 5 mons 360 hours      | Sun Jun 15 17:32:01 2003 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 years 5 mons 360 hours      | Mon Jun 16 17:32:01 2003 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 years 5 mons -360 hours     | Thu Jul 31 02:14:05 2003 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 years 5 mons -360 hours     | Thu Jul 31 03:14:04 2003 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 years 5 mons -360 hours     | Thu Jul 31 08:14:01 2003 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 years 5 mons -360 hours     | Thu Jul 31 12:14:03 2003 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 years 5 mons -360 hours     | Thu Jul 31 13:14:02 2003 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 years 5 mons                | Fri Aug 15 02:14:05 2003 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 years 5 mons                | Fri Aug 15 03:14:04 2003 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 years 5 mons                | Fri Aug 15 08:14:01 2003 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 years 5 mons                | Fri Aug 15 12:14:03 2003 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 years 5 mons                | Fri Aug 15 13:14:02 2003 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 years 5 mons 360 hours      | Sat Aug 30 02:14:05 2003 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 years 5 mons 360 hours      | Sat Aug 30 03:14:04 2003 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 years 5 mons 360 hours      | Sat Aug 30 08:14:01 2003 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 years 5 mons 360 hours      | Sat Aug 30 12:14:03 2003 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 years 5 mons 360 hours      | Sat Aug 30 13:14:02 2003 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 34 years                      | Thu Jan 01 00:00:00 2004 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 years 5 mons -360 hours     | Sun May 16 17:32:01 2004 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 years 5 mons -360 hours     | Mon May 17 17:32:01 2004 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 years 5 mons                | Mon May 31 17:32:01 2004 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 years 5 mons                | Tue Jun 01 17:32:01 2004 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 years 5 mons 360 hours      | Tue Jun 15 17:32:01 2004 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 years 5 mons 360 hours      | Wed Jun 16 17:32:01 2004 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 years 5 mons -360 hours     | Mon Feb 07 18:19:20 2005 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 years 5 mons                | Tue Feb 22 18:19:20 2005 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 years 5 mons 360 hours      | Wed Mar 09 18:19:20 2005 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 6 years                       | Sat Dec 31 17:32:01 2005 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 6 years                       | Sun Jan 01 17:32:01 2006 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 6 years                       | Wed Mar 15 02:14:05 2006 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 6 years                       | Wed Mar 15 03:14:04 2006 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 6 years                       | Wed Mar 15 08:14:01 2006 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 6 years                       | Wed Mar 15 12:14:03 2006 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 6 years                       | Wed Mar 15 13:14:02 2006 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 6 years                       | Sun Dec 31 17:32:01 2006 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 6 years                       | Mon Jan 01 17:32:01 2007 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 6 years                       | Sat Sep 22 18:19:20 2007 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 34 years                      | Thu Feb 28 17:32:01 2030 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 34 years                      | Thu Feb 28 17:32:01 2030 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 34 years                      | Fri Mar 01 17:32:01 2030 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 34 years                      | Mon Dec 30 17:32:01 2030 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 34 years                      | Tue Dec 31 17:32:01 2030 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 34 years                      | Sat Dec 31 17:32:01 2033 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 34 years                      | Sun Jan 01 17:32:01 2034 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 34 years                      | Wed Mar 15 02:14:05 2034 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 34 years                      | Wed Mar 15 03:14:04 2034 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 34 years                      | Wed Mar 15 08:14:01 2034 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 34 years                      | Wed Mar 15 12:14:03 2034 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 34 years                      | Wed Mar 15 13:14:02 2034 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 34 years                      | Sun Dec 31 17:32:01 2034 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 34 years                      | Mon Jan 01 17:32:01 2035 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 34 years                      | Sat Sep 22 18:19:20 2035 PDT
! (240 rows)
  
! SELECT '' AS "240", d.f1 AS "timestamp", t.f1 AS "interval", d.f1 - t.f1 AS minus
    FROM TEMP_TIMESTAMP d, INTERVAL_TBL t
    WHERE isfinite(d.f1)
    ORDER BY minus, "timestamp", "interval";
!  240 |          timestamp           |            interval             |            minus             
! -----+------------------------------+---------------------------------+------------------------------
!      | Thu Jan 01 00:00:00 1970 PST | @ 34 years                      | Wed Jan 01 00:00:00 1936 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 34 years                      | Wed Feb 28 17:32:01 1962 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 34 years                      | Wed Feb 28 17:32:01 1962 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 34 years                      | Thu Mar 01 17:32:01 1962 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 34 years                      | Sun Dec 30 17:32:01 1962 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 34 years                      | Mon Dec 31 17:32:01 1962 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 6 years                       | Wed Jan 01 00:00:00 1964 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 34 years                      | Fri Dec 31 17:32:01 1965 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 34 years                      | Sat Jan 01 17:32:01 1966 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 34 years                      | Tue Mar 15 02:14:05 1966 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 34 years                      | Tue Mar 15 03:14:04 1966 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 34 years                      | Tue Mar 15 08:14:01 1966 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 34 years                      | Tue Mar 15 12:14:03 1966 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 34 years                      | Tue Mar 15 13:14:02 1966 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 years 5 mons 360 hours      | Sun Jul 17 00:00:00 1966 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 years 5 mons                | Mon Aug 01 00:00:00 1966 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 years 5 mons -360 hours     | Tue Aug 16 00:00:00 1966 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 34 years                      | Sat Dec 31 17:32:01 1966 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 34 years                      | Sun Jan 01 17:32:01 1967 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 34 years                      | Fri Sep 22 18:19:20 1967 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 5 mons 12 hours               | Thu Jul 31 12:00:00 1969 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 5 mons                        | Fri Aug 01 00:00:00 1969 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 mons                        | Wed Oct 01 00:00:00 1969 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 10 days                       | Mon Dec 22 00:00:00 1969 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 1 day 2 hours 3 mins 4 secs   | Tue Dec 30 21:56:56 1969 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 5 hours                       | Wed Dec 31 19:00:00 1969 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 1 min                         | Wed Dec 31 23:59:00 1969 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 14 secs ago                   | Thu Jan 01 00:00:14 1970 PST
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 years 5 mons -360 hours ago | Thu May 17 00:00:00 1973 PDT
!      | Thu Jan 01 00:00:00 1970 PST | @ 3 years 5 mons 360 hours ago  | Sat Jun 16 00:00:00 1973 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 6 years                       | Wed Feb 28 17:32:01 1990 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 6 years                       | Wed Feb 28 17:32:01 1990 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 6 years                       | Thu Mar 01 17:32:01 1990 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 6 years                       | Sun Dec 30 17:32:01 1990 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 6 years                       | Mon Dec 31 17:32:01 1990 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 years 5 mons 360 hours      | Sun Sep 13 17:32:01 1992 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 years 5 mons 360 hours      | Mon Sep 14 17:32:01 1992 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 years 5 mons 360 hours      | Wed Sep 16 17:32:01 1992 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 years 5 mons                | Mon Sep 28 17:32:01 1992 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 years 5 mons                | Tue Sep 29 17:32:01 1992 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 years 5 mons                | Thu Oct 01 17:32:01 1992 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 years 5 mons -360 hours     | Tue Oct 13 17:32:01 1992 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 years 5 mons -360 hours     | Wed Oct 14 17:32:01 1992 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 years 5 mons -360 hours     | Fri Oct 16 17:32:01 1992 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 years 5 mons 360 hours      | Thu Jul 15 17:32:01 1993 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 years 5 mons 360 hours      | Fri Jul 16 17:32:01 1993 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 years 5 mons                | Fri Jul 30 17:32:01 1993 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 years 5 mons                | Sat Jul 31 17:32:01 1993 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 years 5 mons -360 hours     | Sat Aug 14 17:32:01 1993 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 years 5 mons -360 hours     | Sun Aug 15 17:32:01 1993 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 6 years                       | Fri Dec 31 17:32:01 1993 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 6 years                       | Sat Jan 01 17:32:01 1994 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 6 years                       | Tue Mar 15 02:14:05 1994 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 6 years                       | Tue Mar 15 03:14:04 1994 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 6 years                       | Tue Mar 15 08:14:01 1994 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 6 years                       | Tue Mar 15 12:14:03 1994 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 6 years                       | Tue Mar 15 13:14:02 1994 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 6 years                       | Sat Dec 31 17:32:01 1994 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 6 years                       | Sun Jan 01 17:32:01 1995 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 6 years                       | Fri Sep 22 18:19:20 1995 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 5 mons 12 hours               | Thu Sep 28 05:32:01 1995 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 5 mons                        | Thu Sep 28 17:32:01 1995 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 5 mons 12 hours               | Fri Sep 29 05:32:01 1995 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 5 mons                        | Fri Sep 29 17:32:01 1995 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 5 mons 12 hours               | Sun Oct 01 05:32:01 1995 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 5 mons                        | Sun Oct 01 17:32:01 1995 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 mons                        | Tue Nov 28 17:32:01 1995 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 mons                        | Wed Nov 29 17:32:01 1995 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 mons                        | Fri Dec 01 17:32:01 1995 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 10 days                       | Sun Feb 18 17:32:01 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 10 days                       | Mon Feb 19 17:32:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 10 days                       | Tue Feb 20 17:32:01 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs   | Tue Feb 27 15:28:57 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 5 hours                       | Wed Feb 28 12:32:01 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs   | Wed Feb 28 15:28:57 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 1 min                         | Wed Feb 28 17:31:01 1996 PST
!      | Wed Feb 28 17:32:01 1996 PST | @ 14 secs ago                   | Wed Feb 28 17:32:15 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 5 hours                       | Thu Feb 29 12:32:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs   | Thu Feb 29 15:28:57 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 1 min                         | Thu Feb 29 17:31:01 1996 PST
!      | Thu Feb 29 17:32:01 1996 PST | @ 14 secs ago                   | Thu Feb 29 17:32:15 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 5 hours                       | Fri Mar 01 12:32:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 1 min                         | Fri Mar 01 17:31:01 1996 PST
!      | Fri Mar 01 17:32:01 1996 PST | @ 14 secs ago                   | Fri Mar 01 17:32:15 1996 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 years 5 mons 360 hours      | Tue Jul 16 17:32:01 1996 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 years 5 mons 360 hours      | Wed Jul 17 17:32:01 1996 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 5 mons 12 hours               | Tue Jul 30 05:32:01 1996 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 5 mons                        | Tue Jul 30 17:32:01 1996 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 5 mons 12 hours               | Wed Jul 31 05:32:01 1996 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 5 mons                        | Wed Jul 31 17:32:01 1996 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 years 5 mons                | Wed Jul 31 17:32:01 1996 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 years 5 mons                | Thu Aug 01 17:32:01 1996 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 years 5 mons -360 hours     | Thu Aug 15 17:32:01 1996 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 years 5 mons -360 hours     | Fri Aug 16 17:32:01 1996 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 years 5 mons 360 hours      | Mon Sep 30 02:14:05 1996 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 years 5 mons 360 hours      | Mon Sep 30 03:14:04 1996 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 years 5 mons 360 hours      | Mon Sep 30 08:14:01 1996 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 years 5 mons 360 hours      | Mon Sep 30 12:14:03 1996 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 years 5 mons 360 hours      | Mon Sep 30 13:14:02 1996 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 mons                        | Mon Sep 30 17:32:01 1996 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 mons                        | Mon Sep 30 17:32:01 1996 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 years 5 mons                | Tue Oct 15 02:14:05 1996 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 years 5 mons                | Tue Oct 15 03:14:04 1996 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 years 5 mons                | Tue Oct 15 08:14:01 1996 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 years 5 mons                | Tue Oct 15 12:14:03 1996 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 years 5 mons                | Tue Oct 15 13:14:02 1996 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 years 5 mons -360 hours     | Wed Oct 30 01:14:05 1996 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 years 5 mons -360 hours     | Wed Oct 30 02:14:04 1996 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 years 5 mons -360 hours     | Wed Oct 30 07:14:01 1996 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 years 5 mons -360 hours     | Wed Oct 30 11:14:03 1996 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 years 5 mons -360 hours     | Wed Oct 30 12:14:02 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 10 days                       | Fri Dec 20 17:32:01 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 10 days                       | Sat Dec 21 17:32:01 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs   | Sun Dec 29 15:28:57 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 5 hours                       | Mon Dec 30 12:32:01 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 1 day 2 hours 3 mins 4 secs   | Mon Dec 30 15:28:57 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 1 min                         | Mon Dec 30 17:31:01 1996 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 14 secs ago                   | Mon Dec 30 17:32:15 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 5 hours                       | Tue Dec 31 12:32:01 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 1 min                         | Tue Dec 31 17:31:01 1996 PST
!      | Tue Dec 31 17:32:01 1996 PST | @ 14 secs ago                   | Tue Dec 31 17:32:15 1996 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 years 5 mons 360 hours      | Wed Jul 16 17:32:01 1997 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 years 5 mons 360 hours      | Thu Jul 17 17:32:01 1997 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 years 5 mons                | Thu Jul 31 17:32:01 1997 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 years 5 mons                | Fri Aug 01 17:32:01 1997 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 years 5 mons -360 hours     | Fri Aug 15 17:32:01 1997 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 years 5 mons -360 hours     | Sat Aug 16 17:32:01 1997 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 years 5 mons 360 hours      | Tue Apr 07 18:19:20 1998 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 years 5 mons                | Wed Apr 22 18:19:20 1998 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 years 5 mons -360 hours     | Thu May 07 18:19:20 1998 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 years 5 mons -360 hours ago | Tue Jul 13 17:32:01 1999 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 years 5 mons -360 hours ago | Wed Jul 14 17:32:01 1999 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 years 5 mons -360 hours ago | Sat Jul 17 17:32:01 1999 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 5 mons 12 hours               | Sat Jul 31 05:32:01 1999 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 5 mons                        | Sat Jul 31 17:32:01 1999 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 5 mons 12 hours               | Sun Aug 01 05:32:01 1999 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 5 mons                        | Sun Aug 01 17:32:01 1999 PDT
!      | Wed Feb 28 17:32:01 1996 PST | @ 3 years 5 mons 360 hours ago  | Thu Aug 12 17:32:01 1999 PDT
!      | Thu Feb 29 17:32:01 1996 PST | @ 3 years 5 mons 360 hours ago  | Fri Aug 13 17:32:01 1999 PDT
!      | Fri Mar 01 17:32:01 1996 PST | @ 3 years 5 mons 360 hours ago  | Mon Aug 16 17:32:01 1999 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 mons                        | Thu Sep 30 17:32:01 1999 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 mons                        | Fri Oct 01 17:32:01 1999 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 5 mons 12 hours               | Thu Oct 14 14:14:05 1999 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 5 mons 12 hours               | Thu Oct 14 15:14:04 1999 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 5 mons 12 hours               | Thu Oct 14 20:14:01 1999 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 5 mons 12 hours               | Fri Oct 15 00:14:03 1999 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 5 mons 12 hours               | Fri Oct 15 01:14:02 1999 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 5 mons                        | Fri Oct 15 02:14:05 1999 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 5 mons                        | Fri Oct 15 03:14:04 1999 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 5 mons                        | Fri Oct 15 08:14:01 1999 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 5 mons                        | Fri Oct 15 12:14:03 1999 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 5 mons                        | Fri Oct 15 13:14:02 1999 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 mons                        | Wed Dec 15 02:14:05 1999 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 mons                        | Wed Dec 15 03:14:04 1999 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 mons                        | Wed Dec 15 08:14:01 1999 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 mons                        | Wed Dec 15 12:14:03 1999 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 mons                        | Wed Dec 15 13:14:02 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 10 days                       | Tue Dec 21 17:32:01 1999 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 10 days                       | Wed Dec 22 17:32:01 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 1 day 2 hours 3 mins 4 secs   | Thu Dec 30 15:28:57 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 5 hours                       | Fri Dec 31 12:32:01 1999 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Fri Dec 31 15:28:57 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 1 min                         | Fri Dec 31 17:31:01 1999 PST
!      | Fri Dec 31 17:32:01 1999 PST | @ 14 secs ago                   | Fri Dec 31 17:32:15 1999 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 5 hours                       | Sat Jan 01 12:32:01 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 1 min                         | Sat Jan 01 17:31:01 2000 PST
!      | Sat Jan 01 17:32:01 2000 PST | @ 14 secs ago                   | Sat Jan 01 17:32:15 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 10 days                       | Sun Mar 05 02:14:05 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 10 days                       | Sun Mar 05 03:14:04 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 10 days                       | Sun Mar 05 08:14:01 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 10 days                       | Sun Mar 05 12:14:03 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 10 days                       | Sun Mar 05 13:14:02 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Tue Mar 14 00:11:01 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Tue Mar 14 01:11:00 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Tue Mar 14 06:10:57 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Tue Mar 14 10:10:59 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Tue Mar 14 11:10:58 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 5 hours                       | Tue Mar 14 21:14:05 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 5 hours                       | Tue Mar 14 22:14:04 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 1 min                         | Wed Mar 15 02:13:05 2000 PST
!      | Wed Mar 15 02:14:05 2000 PST | @ 14 secs ago                   | Wed Mar 15 02:14:19 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 1 min                         | Wed Mar 15 03:13:04 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 5 hours                       | Wed Mar 15 03:14:01 2000 PST
!      | Wed Mar 15 03:14:04 2000 PST | @ 14 secs ago                   | Wed Mar 15 03:14:18 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 5 hours                       | Wed Mar 15 07:14:03 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 1 min                         | Wed Mar 15 08:13:01 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 5 hours                       | Wed Mar 15 08:14:02 2000 PST
!      | Wed Mar 15 08:14:01 2000 PST | @ 14 secs ago                   | Wed Mar 15 08:14:15 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 1 min                         | Wed Mar 15 12:13:03 2000 PST
!      | Wed Mar 15 12:14:03 2000 PST | @ 14 secs ago                   | Wed Mar 15 12:14:17 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 1 min                         | Wed Mar 15 13:13:02 2000 PST
!      | Wed Mar 15 13:14:02 2000 PST | @ 14 secs ago                   | Wed Mar 15 13:14:16 2000 PST
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 years 5 mons -360 hours ago | Mon May 15 17:32:01 2000 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 years 5 mons -360 hours ago | Tue May 16 17:32:01 2000 PDT
!      | Mon Dec 30 17:32:01 1996 PST | @ 3 years 5 mons 360 hours ago  | Wed Jun 14 17:32:01 2000 PDT
!      | Tue Dec 31 17:32:01 1996 PST | @ 3 years 5 mons 360 hours ago  | Thu Jun 15 17:32:01 2000 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 5 mons 12 hours               | Mon Jul 31 05:32:01 2000 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 5 mons                        | Mon Jul 31 17:32:01 2000 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 5 mons 12 hours               | Tue Aug 01 05:32:01 2000 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 5 mons                        | Tue Aug 01 17:32:01 2000 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 mons                        | Sat Sep 30 17:32:01 2000 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 mons                        | Sun Oct 01 17:32:01 2000 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 10 days                       | Thu Dec 21 17:32:01 2000 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 10 days                       | Fri Dec 22 17:32:01 2000 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 1 day 2 hours 3 mins 4 secs   | Sat Dec 30 15:28:57 2000 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 5 hours                       | Sun Dec 31 12:32:01 2000 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 1 day 2 hours 3 mins 4 secs   | Sun Dec 31 15:28:57 2000 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 1 min                         | Sun Dec 31 17:31:01 2000 PST
!      | Sun Dec 31 17:32:01 2000 PST | @ 14 secs ago                   | Sun Dec 31 17:32:15 2000 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 5 hours                       | Mon Jan 01 12:32:01 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 1 min                         | Mon Jan 01 17:31:01 2001 PST
!      | Mon Jan 01 17:32:01 2001 PST | @ 14 secs ago                   | Mon Jan 01 17:32:15 2001 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 5 mons 12 hours               | Sun Apr 22 06:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 5 mons                        | Sun Apr 22 18:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 mons                        | Fri Jun 22 18:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 10 days                       | Wed Sep 12 18:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 1 day 2 hours 3 mins 4 secs   | Fri Sep 21 16:16:16 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 5 hours                       | Sat Sep 22 13:19:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 1 min                         | Sat Sep 22 18:18:20 2001 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 14 secs ago                   | Sat Sep 22 18:19:34 2001 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 years 5 mons -360 hours ago | Fri May 16 17:32:01 2003 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 years 5 mons -360 hours ago | Sat May 17 17:32:01 2003 PDT
!      | Fri Dec 31 17:32:01 1999 PST | @ 3 years 5 mons 360 hours ago  | Sun Jun 15 17:32:01 2003 PDT
!      | Sat Jan 01 17:32:01 2000 PST | @ 3 years 5 mons 360 hours ago  | Mon Jun 16 17:32:01 2003 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 years 5 mons -360 hours ago | Thu Jul 31 02:14:05 2003 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 years 5 mons -360 hours ago | Thu Jul 31 03:14:04 2003 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 years 5 mons -360 hours ago | Thu Jul 31 08:14:01 2003 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 years 5 mons -360 hours ago | Thu Jul 31 12:14:03 2003 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 years 5 mons -360 hours ago | Thu Jul 31 13:14:02 2003 PDT
!      | Wed Mar 15 02:14:05 2000 PST | @ 3 years 5 mons 360 hours ago  | Sat Aug 30 02:14:05 2003 PDT
!      | Wed Mar 15 03:14:04 2000 PST | @ 3 years 5 mons 360 hours ago  | Sat Aug 30 03:14:04 2003 PDT
!      | Wed Mar 15 08:14:01 2000 PST | @ 3 years 5 mons 360 hours ago  | Sat Aug 30 08:14:01 2003 PDT
!      | Wed Mar 15 12:14:03 2000 PST | @ 3 years 5 mons 360 hours ago  | Sat Aug 30 12:14:03 2003 PDT
!      | Wed Mar 15 13:14:02 2000 PST | @ 3 years 5 mons 360 hours ago  | Sat Aug 30 13:14:02 2003 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 years 5 mons -360 hours ago | Sun May 16 17:32:01 2004 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 years 5 mons -360 hours ago | Mon May 17 17:32:01 2004 PDT
!      | Sun Dec 31 17:32:01 2000 PST | @ 3 years 5 mons 360 hours ago  | Tue Jun 15 17:32:01 2004 PDT
!      | Mon Jan 01 17:32:01 2001 PST | @ 3 years 5 mons 360 hours ago  | Wed Jun 16 17:32:01 2004 PDT
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 years 5 mons -360 hours ago | Mon Feb 07 18:19:20 2005 PST
!      | Sat Sep 22 18:19:20 2001 PDT | @ 3 years 5 mons 360 hours ago  | Wed Mar 09 18:19:20 2005 PST
! (240 rows)
  
  SELECT '' AS "16", d.f1 AS "timestamp",
     timestamp with time zone '1980-01-06 00:00 GMT' AS gpstime_zero,
***************
*** 2463,2483 ****
  SELECT '' AS three, f1 as abstime, cast(f1 as timestamp) AS "timestamp"
    FROM ABSTIME_TBL WHERE NOT isfinite(f1);
  ERROR:  cannot convert abstime "invalid" to timestamp
! SELECT '' AS ten, f1 AS interval, reltime(f1) AS reltime
    FROM INTERVAL_TBL;
!  ten |           interval            |            reltime            
! -----+-------------------------------+-------------------------------
!      | @ 1 min                       | @ 1 min
!      | @ 5 hours                     | @ 5 hours
!      | @ 10 days                     | @ 10 days
!      | @ 34 years                    | @ 34 years
!      | @ 3 mons                      | @ 3 mons
!      | @ 14 secs ago                 | @ 14 secs ago
!      | @ 1 day 2 hours 3 mins 4 secs | @ 1 day 2 hours 3 mins 4 secs
!      | @ 6 years                     | @ 6 years
!      | @ 5 mons                      | @ 5 mons
!      | @ 5 mons 12 hours             | @ 5 mons 12 hours
! (10 rows)
  
  SELECT '' AS six, f1 as reltime, CAST(f1 AS interval) AS interval
    FROM RELTIME_TBL;
--- 2843,2868 ----
  SELECT '' AS three, f1 as abstime, cast(f1 as timestamp) AS "timestamp"
    FROM ABSTIME_TBL WHERE NOT isfinite(f1);
  ERROR:  cannot convert abstime "invalid" to timestamp
! SELECT '' AS fifteen, f1 AS interval, reltime(f1) AS reltime
    FROM INTERVAL_TBL;
!  fifteen |            interval             |            reltime            
! ---------+---------------------------------+-------------------------------
!          | @ 1 min                         | @ 1 min
!          | @ 5 hours                       | @ 5 hours
!          | @ 10 days                       | @ 10 days
!          | @ 34 years                      | @ 34 years
!          | @ 3 mons                        | @ 3 mons
!          | @ 14 secs ago                   | @ 14 secs ago
!          | @ 1 day 2 hours 3 mins 4 secs   | @ 1 day 2 hours 3 mins 4 secs
!          | @ 6 years                       | @ 6 years
!          | @ 5 mons                        | @ 5 mons
!          | @ 5 mons 12 hours               | @ 5 mons 12 hours
!          | @ 3 years 5 mons                | @ 3 years 5 mons
!          | @ 3 years 5 mons 360 hours      | @ 3 years 5 mons 15 days
!          | @ 3 years 5 mons -360 hours     | @ 3 years 4 mons 15 days
!          | @ 3 years 5 mons -360 hours ago | @ 3 years 4 mons 15 days ago
!          | @ 3 years 5 mons 360 hours ago  | @ 3 years 5 mons 15 days ago
! (15 rows)
  
  SELECT '' AS six, f1 as reltime, CAST(f1 AS interval) AS interval
    FROM RELTIME_TBL;
Index: src/test/regress/expected/interval.out
===================================================================
RCS file: /projects/cvsroot/pgsql/src/test/regress/expected/interval.out,v
retrieving revision 1.15
diff -c -r1.15 interval.out
*** src/test/regress/expected/interval.out	6 Mar 2006 22:49:17 -0000	1.15
--- src/test/regress/expected/interval.out	29 Aug 2006 14:42:37 -0000
***************
*** 56,114 ****
  INSERT INTO INTERVAL_TBL (f1) VALUES ('6 years');
  INSERT INTO INTERVAL_TBL (f1) VALUES ('5 months');
  INSERT INTO INTERVAL_TBL (f1) VALUES ('5 months 12 hours');
  -- badly formatted interval
  INSERT INTO INTERVAL_TBL (f1) VALUES ('badly formatted interval');
  ERROR:  invalid input syntax for type interval: "badly formatted interval"
  INSERT INTO INTERVAL_TBL (f1) VALUES ('@ 30 eons ago');
  ERROR:  invalid input syntax for type interval: "@ 30 eons ago"
  -- test interval operators
! SELECT '' AS ten, * FROM INTERVAL_TBL;
!  ten |       f1        
! -----+-----------------
!      | 00:01:00
!      | 05:00:00
!      | 10 days
!      | 34 years
!      | 3 mons
!      | -00:00:14
!      | 1 day 02:03:04
!      | 6 years
!      | 5 mons
!      | 5 mons 12:00:00
! (10 rows)
  
! SELECT '' AS nine, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 <> interval '@ 10 days';
!  nine |       f1        
! ------+-----------------
        | 00:01:00
        | 05:00:00
-       | 34 years
-       | 3 mons
        | -00:00:14
!       | 1 day 02:03:04
!       | 6 years
!       | 5 mons
!       | 5 mons 12:00:00
! (9 rows)
! 
! SELECT '' AS three, * FROM INTERVAL_TBL
!    WHERE INTERVAL_TBL.f1 <= interval '@ 5 hours';
!  three |    f1     
! -------+-----------
!        | 00:01:00
!        | 05:00:00
!        | -00:00:14
! (3 rows)
  
! SELECT '' AS three, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 < interval '@ 1 day';
!  three |    f1     
! -------+-----------
!        | 00:01:00
!        | 05:00:00
!        | -00:00:14
! (3 rows)
  
  SELECT '' AS one, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 = interval '@ 34 years';
--- 56,133 ----
  INSERT INTO INTERVAL_TBL (f1) VALUES ('6 years');
  INSERT INTO INTERVAL_TBL (f1) VALUES ('5 months');
  INSERT INTO INTERVAL_TBL (f1) VALUES ('5 months 12 hours');
+ INSERT INTO INTERVAL_TBL (f1) VALUES ('41 mon');
+ INSERT INTO INTERVAL_TBL (f1) VALUES ('41 mon 360:00');
+ INSERT INTO INTERVAL_TBL (f1) VALUES ('41 mon -360:00');
+ INSERT INTO INTERVAL_TBL (f1) VALUES ('-41 mon 360:00');
+ INSERT INTO INTERVAL_TBL (f1) VALUES ('-41 mon -360:00');
  -- badly formatted interval
  INSERT INTO INTERVAL_TBL (f1) VALUES ('badly formatted interval');
  ERROR:  invalid input syntax for type interval: "badly formatted interval"
  INSERT INTO INTERVAL_TBL (f1) VALUES ('@ 30 eons ago');
  ERROR:  invalid input syntax for type interval: "@ 30 eons ago"
  -- test interval operators
! SELECT '' AS fifteen, * FROM INTERVAL_TBL;
!  fifteen |             f1              
! ---------+-----------------------------
!          | 00:01:00
!          | 05:00:00
!          | 10 days
!          | 34 years
!          | 3 mons
!          | -00:00:14
!          | 1 day 02:03:04
!          | 6 years
!          | 5 mons
!          | 5 mons 12:00:00
!          | 3 years 5 mons
!          | 3 years 5 mons 360:00:00
!          | 3 years 5 mons -360:00:00
!          | -3 years -5 mons +360:00:00
!          | -3 years -5 mons -360:00:00
! (15 rows)
  
! SELECT '' AS fourteen, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 <> interval '@ 10 days';
!  fourteen |             f1              
! ----------+-----------------------------
!           | 00:01:00
!           | 05:00:00
!           | 34 years
!           | 3 mons
!           | -00:00:14
!           | 1 day 02:03:04
!           | 6 years
!           | 5 mons
!           | 5 mons 12:00:00
!           | 3 years 5 mons
!           | 3 years 5 mons 360:00:00
!           | 3 years 5 mons -360:00:00
!           | -3 years -5 mons +360:00:00
!           | -3 years -5 mons -360:00:00
! (14 rows)
! 
! SELECT '' AS five, * FROM INTERVAL_TBL
!    WHERE INTERVAL_TBL.f1 <= interval '@ 5 hours';
!  five |             f1              
! ------+-----------------------------
        | 00:01:00
        | 05:00:00
        | -00:00:14
!       | -3 years -5 mons +360:00:00
!       | -3 years -5 mons -360:00:00
! (5 rows)
  
! SELECT '' AS five, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 < interval '@ 1 day';
!  five |             f1              
! ------+-----------------------------
!       | 00:01:00
!       | 05:00:00
!       | -00:00:14
!       | -3 years -5 mons +360:00:00
!       | -3 years -5 mons -360:00:00
! (5 rows)
  
  SELECT '' AS one, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 = interval '@ 34 years';
***************
*** 117,226 ****
       | 34 years
  (1 row)
  
! SELECT '' AS five, * FROM INTERVAL_TBL 
     WHERE INTERVAL_TBL.f1 >= interval '@ 1 month';
!  five |       f1        
! ------+-----------------
!       | 34 years
!       | 3 mons
!       | 6 years
!       | 5 mons
!       | 5 mons 12:00:00
! (5 rows)
  
! SELECT '' AS nine, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 > interval '@ 3 seconds ago';
!  nine |       f1        
! ------+-----------------
!       | 00:01:00
!       | 05:00:00
!       | 10 days
!       | 34 years
!       | 3 mons
!       | 1 day 02:03:04
!       | 6 years
!       | 5 mons
!       | 5 mons 12:00:00
! (9 rows)
  
! SELECT '' AS fortyfive, r1.*, r2.*
     FROM INTERVAL_TBL r1, INTERVAL_TBL r2
     WHERE r1.f1 > r2.f1
     ORDER BY r1.f1, r2.f1;
!  fortyfive |       f1        |       f1        
! -----------+-----------------+-----------------
!            | 00:01:00        | -00:00:14
!            | 05:00:00        | -00:00:14
!            | 05:00:00        | 00:01:00
!            | 1 day 02:03:04  | -00:00:14
!            | 1 day 02:03:04  | 00:01:00
!            | 1 day 02:03:04  | 05:00:00
!            | 10 days         | -00:00:14
!            | 10 days         | 00:01:00
!            | 10 days         | 05:00:00
!            | 10 days         | 1 day 02:03:04
!            | 3 mons          | -00:00:14
!            | 3 mons          | 00:01:00
!            | 3 mons          | 05:00:00
!            | 3 mons          | 1 day 02:03:04
!            | 3 mons          | 10 days
!            | 5 mons          | -00:00:14
!            | 5 mons          | 00:01:00
!            | 5 mons          | 05:00:00
!            | 5 mons          | 1 day 02:03:04
!            | 5 mons          | 10 days
!            | 5 mons          | 3 mons
!            | 5 mons 12:00:00 | -00:00:14
!            | 5 mons 12:00:00 | 00:01:00
!            | 5 mons 12:00:00 | 05:00:00
!            | 5 mons 12:00:00 | 1 day 02:03:04
!            | 5 mons 12:00:00 | 10 days
!            | 5 mons 12:00:00 | 3 mons
!            | 5 mons 12:00:00 | 5 mons
!            | 6 years         | -00:00:14
!            | 6 years         | 00:01:00
!            | 6 years         | 05:00:00
!            | 6 years         | 1 day 02:03:04
!            | 6 years         | 10 days
!            | 6 years         | 3 mons
!            | 6 years         | 5 mons
!            | 6 years         | 5 mons 12:00:00
!            | 34 years        | -00:00:14
!            | 34 years        | 00:01:00
!            | 34 years        | 05:00:00
!            | 34 years        | 1 day 02:03:04
!            | 34 years        | 10 days
!            | 34 years        | 3 mons
!            | 34 years        | 5 mons
!            | 34 years        | 5 mons 12:00:00
!            | 34 years        | 6 years
! (45 rows)
  
  SET DATESTYLE = 'postgres';
! SELECT '' AS ten, * FROM INTERVAL_TBL;
!  ten |              f1               
! -----+-------------------------------
!      | @ 1 min
!      | @ 5 hours
!      | @ 10 days
!      | @ 34 years
!      | @ 3 mons
!      | @ 14 secs ago
!      | @ 1 day 2 hours 3 mins 4 secs
!      | @ 6 years
!      | @ 5 mons
!      | @ 5 mons 12 hours
! (10 rows)
  
  -- test avg(interval), which is somewhat fragile since people have been
  -- known to change the allowed input syntax for type interval without
  -- updating pg_aggregate.agginitval
  select avg(f1) from interval_tbl;
!                        avg                       
! -------------------------------------------------
!  @ 4 years 1 mon 9 days 28 hours 18 mins 23 secs
  (1 row)
  
  -- test long interval input
  select '4 millenniums 5 centuries 4 decades 1 year 4 months 4 days 17 minutes 31 seconds'::interval;
                    interval                  
--- 136,360 ----
       | 34 years
  (1 row)
  
! SELECT '' AS eight, * FROM INTERVAL_TBL 
     WHERE INTERVAL_TBL.f1 >= interval '@ 1 month';
!  eight |            f1             
! -------+---------------------------
!        | 34 years
!        | 3 mons
!        | 6 years
!        | 5 mons
!        | 5 mons 12:00:00
!        | 3 years 5 mons
!        | 3 years 5 mons 360:00:00
!        | 3 years 5 mons -360:00:00
! (8 rows)
  
! SELECT '' AS twelve, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 > interval '@ 3 seconds ago';
!  twelve |            f1             
! --------+---------------------------
!         | 00:01:00
!         | 05:00:00
!         | 10 days
!         | 34 years
!         | 3 mons
!         | 1 day 02:03:04
!         | 6 years
!         | 5 mons
!         | 5 mons 12:00:00
!         | 3 years 5 mons
!         | 3 years 5 mons 360:00:00
!         | 3 years 5 mons -360:00:00
! (12 rows)
  
! SELECT '' AS onehundredfive, r1.*, r2.*
     FROM INTERVAL_TBL r1, INTERVAL_TBL r2
     WHERE r1.f1 > r2.f1
     ORDER BY r1.f1, r2.f1;
!  onehundredfive |             f1              |             f1              
! ----------------+-----------------------------+-----------------------------
!                 | -3 years -5 mons +360:00:00 | -3 years -5 mons -360:00:00
!                 | -00:00:14                   | -3 years -5 mons -360:00:00
!                 | -00:00:14                   | -3 years -5 mons +360:00:00
!                 | 00:01:00                    | -3 years -5 mons -360:00:00
!                 | 00:01:00                    | -3 years -5 mons +360:00:00
!                 | 00:01:00                    | -00:00:14
!                 | 05:00:00                    | -3 years -5 mons -360:00:00
!                 | 05:00:00                    | -3 years -5 mons +360:00:00
!                 | 05:00:00                    | -00:00:14
!                 | 05:00:00                    | 00:01:00
!                 | 1 day 02:03:04              | -3 years -5 mons -360:00:00
!                 | 1 day 02:03:04              | -3 years -5 mons +360:00:00
!                 | 1 day 02:03:04              | -00:00:14
!                 | 1 day 02:03:04              | 00:01:00
!                 | 1 day 02:03:04              | 05:00:00
!                 | 10 days                     | -3 years -5 mons -360:00:00
!                 | 10 days                     | -3 years -5 mons +360:00:00
!                 | 10 days                     | -00:00:14
!                 | 10 days                     | 00:01:00
!                 | 10 days                     | 05:00:00
!                 | 10 days                     | 1 day 02:03:04
!                 | 3 mons                      | -3 years -5 mons -360:00:00
!                 | 3 mons                      | -3 years -5 mons +360:00:00
!                 | 3 mons                      | -00:00:14
!                 | 3 mons                      | 00:01:00
!                 | 3 mons                      | 05:00:00
!                 | 3 mons                      | 1 day 02:03:04
!                 | 3 mons                      | 10 days
!                 | 5 mons                      | -3 years -5 mons -360:00:00
!                 | 5 mons                      | -3 years -5 mons +360:00:00
!                 | 5 mons                      | -00:00:14
!                 | 5 mons                      | 00:01:00
!                 | 5 mons                      | 05:00:00
!                 | 5 mons                      | 1 day 02:03:04
!                 | 5 mons                      | 10 days
!                 | 5 mons                      | 3 mons
!                 | 5 mons 12:00:00             | -3 years -5 mons -360:00:00
!                 | 5 mons 12:00:00             | -3 years -5 mons +360:00:00
!                 | 5 mons 12:00:00             | -00:00:14
!                 | 5 mons 12:00:00             | 00:01:00
!                 | 5 mons 12:00:00             | 05:00:00
!                 | 5 mons 12:00:00             | 1 day 02:03:04
!                 | 5 mons 12:00:00             | 10 days
!                 | 5 mons 12:00:00             | 3 mons
!                 | 5 mons 12:00:00             | 5 mons
!                 | 3 years 5 mons -360:00:00   | -3 years -5 mons -360:00:00
!                 | 3 years 5 mons -360:00:00   | -3 years -5 mons +360:00:00
!                 | 3 years 5 mons -360:00:00   | -00:00:14
!                 | 3 years 5 mons -360:00:00   | 00:01:00
!                 | 3 years 5 mons -360:00:00   | 05:00:00
!                 | 3 years 5 mons -360:00:00   | 1 day 02:03:04
!                 | 3 years 5 mons -360:00:00   | 10 days
!                 | 3 years 5 mons -360:00:00   | 3 mons
!                 | 3 years 5 mons -360:00:00   | 5 mons
!                 | 3 years 5 mons -360:00:00   | 5 mons 12:00:00
!                 | 3 years 5 mons              | -3 years -5 mons -360:00:00
!                 | 3 years 5 mons              | -3 years -5 mons +360:00:00
!                 | 3 years 5 mons              | -00:00:14
!                 | 3 years 5 mons              | 00:01:00
!                 | 3 years 5 mons              | 05:00:00
!                 | 3 years 5 mons              | 1 day 02:03:04
!                 | 3 years 5 mons              | 10 days
!                 | 3 years 5 mons              | 3 mons
!                 | 3 years 5 mons              | 5 mons
!                 | 3 years 5 mons              | 5 mons 12:00:00
!                 | 3 years 5 mons              | 3 years 5 mons -360:00:00
!                 | 3 years 5 mons 360:00:00    | -3 years -5 mons -360:00:00
!                 | 3 years 5 mons 360:00:00    | -3 years -5 mons +360:00:00
!                 | 3 years 5 mons 360:00:00    | -00:00:14
!                 | 3 years 5 mons 360:00:00    | 00:01:00
!                 | 3 years 5 mons 360:00:00    | 05:00:00
!                 | 3 years 5 mons 360:00:00    | 1 day 02:03:04
!                 | 3 years 5 mons 360:00:00    | 10 days
!                 | 3 years 5 mons 360:00:00    | 3 mons
!                 | 3 years 5 mons 360:00:00    | 5 mons
!                 | 3 years 5 mons 360:00:00    | 5 mons 12:00:00
!                 | 3 years 5 mons 360:00:00    | 3 years 5 mons -360:00:00
!                 | 3 years 5 mons 360:00:00    | 3 years 5 mons
!                 | 6 years                     | -3 years -5 mons -360:00:00
!                 | 6 years                     | -3 years -5 mons +360:00:00
!                 | 6 years                     | -00:00:14
!                 | 6 years                     | 00:01:00
!                 | 6 years                     | 05:00:00
!                 | 6 years                     | 1 day 02:03:04
!                 | 6 years                     | 10 days
!                 | 6 years                     | 3 mons
!                 | 6 years                     | 5 mons
!                 | 6 years                     | 5 mons 12:00:00
!                 | 6 years                     | 3 years 5 mons -360:00:00
!                 | 6 years                     | 3 years 5 mons
!                 | 6 years                     | 3 years 5 mons 360:00:00
!                 | 34 years                    | -3 years -5 mons -360:00:00
!                 | 34 years                    | -3 years -5 mons +360:00:00
!                 | 34 years                    | -00:00:14
!                 | 34 years                    | 00:01:00
!                 | 34 years                    | 05:00:00
!                 | 34 years                    | 1 day 02:03:04
!                 | 34 years                    | 10 days
!                 | 34 years                    | 3 mons
!                 | 34 years                    | 5 mons
!                 | 34 years                    | 5 mons 12:00:00
!                 | 34 years                    | 3 years 5 mons -360:00:00
!                 | 34 years                    | 3 years 5 mons
!                 | 34 years                    | 3 years 5 mons 360:00:00
!                 | 34 years                    | 6 years
! (105 rows)
  
  SET DATESTYLE = 'postgres';
! SELECT '' AS fifteen, * FROM INTERVAL_TBL;
!  fifteen |               f1                
! ---------+---------------------------------
!          | @ 1 min
!          | @ 5 hours
!          | @ 10 days
!          | @ 34 years
!          | @ 3 mons
!          | @ 14 secs ago
!          | @ 1 day 2 hours 3 mins 4 secs
!          | @ 6 years
!          | @ 5 mons
!          | @ 5 mons 12 hours
!          | @ 3 years 5 mons
!          | @ 3 years 5 mons 360 hours
!          | @ 3 years 5 mons -360 hours
!          | @ 3 years 5 mons -360 hours ago
!          | @ 3 years 5 mons 360 hours ago
! (15 rows)
  
  -- test avg(interval), which is somewhat fragile since people have been
  -- known to change the allowed input syntax for type interval without
  -- updating pg_aggregate.agginitval
  select avg(f1) from interval_tbl;
!                           avg                          
! -------------------------------------------------------
!  @ 2 years 11 mons 18 days 18 hours 52 mins 15.33 secs
  (1 row)
  
+ -- Test interval division and multiplication
+ -- Ensures fractional months and days are handled properly
+ SELECT '' AS fourteen, f1 / 10 as quotient
+     FROM INTERVAL_TBL;
+  fourteen |           quotient            
+ ----------+-------------------------------
+           | @ 6 secs
+           | @ 30 mins
+           | @ 1 day
+           | @ 3 years 4 mons 24 days
+           | @ 9 days
+           | @ 1.40 secs ago
+           | @ 2 hours 36 mins 18.40 secs
+           | @ 7 mons 6 days
+           | @ 15 days
+           | @ 15 days 1 hour 12 mins
+           | @ 4 mons 3 days
+           | @ 4 mons 3 days 36 hours
+           | @ 4 mons 3 days -36 hours
+           | @ 4 mons 3 days -36 hours ago
+           | @ 4 mons 3 days 36 hours ago
+ (15 rows)
+ 
+ SELECT '' AS fourteen, f1 * 0.3 as product
+     FROM INTERVAL_TBL;
+  fourteen |             product             
+ ----------+---------------------------------
+           | @ 18 secs
+           | @ 1 hour 30 mins
+           | @ 3 days
+           | @ 10 years 2 mons 12 days
+           | @ 27 days
+           | @ 4.20 secs ago
+           | @ 7 hours 48 mins 55.20 secs
+           | @ 1 year 9 mons 18 days
+           | @ 1 mon 15 days
+           | @ 1 mon 15 days 3 hours 36 mins
+           | @ 1 year 9 days
+           | @ 1 year 9 days 108 hours
+           | @ 1 year 9 days -108 hours
+           | @ 1 year 9 days -108 hours ago
+           | @ 1 year 9 days 108 hours ago
+ (15 rows)
+ 
  -- test long interval input
  select '4 millenniums 5 centuries 4 decades 1 year 4 months 4 days 17 minutes 31 seconds'::interval;
                    interval                  
Index: src/test/regress/sql/horology.sql
===================================================================
RCS file: /projects/cvsroot/pgsql/src/test/regress/sql/horology.sql,v
retrieving revision 1.33
diff -c -r1.33 horology.sql
*** src/test/regress/sql/horology.sql	25 Jul 2006 03:51:22 -0000	1.33
--- src/test/regress/sql/horology.sql	29 Aug 2006 14:42:38 -0000
***************
*** 157,175 ****
  SELECT CAST(cast(date 'today' + time with time zone '03:30'
    + interval '1 month 04:01' as timestamp without time zone) AS time) AS "07:31:00";
  
! SELECT t.d1 + i.f1 AS "102" FROM TIMESTAMP_TBL t, INTERVAL_TBL i
    WHERE t.d1 BETWEEN '1990-01-01' AND '2001-01-01'
      AND i.f1 BETWEEN '00:00' AND '23:00';
  
! SELECT t.d1 - i.f1 AS "102" FROM TIMESTAMP_TBL t, INTERVAL_TBL i
    WHERE t.d1 BETWEEN '1990-01-01' AND '2001-01-01'
      AND i.f1 BETWEEN '00:00' AND '23:00';
  
! SELECT t.f1 + i.f1 AS "80" FROM TIME_TBL t, INTERVAL_TBL i;
! SELECT t.f1 - i.f1 AS "80" FROM TIME_TBL t, INTERVAL_TBL i;
  
! SELECT t.f1 + i.f1 AS "100" FROM TIMETZ_TBL t, INTERVAL_TBL i;
! SELECT t.f1 - i.f1 AS "100" FROM TIMETZ_TBL t, INTERVAL_TBL i;
  
  -- SQL9x OVERLAPS operator
  -- test with time zone
--- 157,175 ----
  SELECT CAST(cast(date 'today' + time with time zone '03:30'
    + interval '1 month 04:01' as timestamp without time zone) AS time) AS "07:31:00";
  
! SELECT t.d1 + i.f1 AS "104" FROM TIMESTAMP_TBL t, INTERVAL_TBL i
    WHERE t.d1 BETWEEN '1990-01-01' AND '2001-01-01'
      AND i.f1 BETWEEN '00:00' AND '23:00';
  
! SELECT t.d1 - i.f1 AS "104" FROM TIMESTAMP_TBL t, INTERVAL_TBL i
    WHERE t.d1 BETWEEN '1990-01-01' AND '2001-01-01'
      AND i.f1 BETWEEN '00:00' AND '23:00';
  
! SELECT t.f1 + i.f1 AS "150" FROM TIME_TBL t, INTERVAL_TBL i;
! SELECT t.f1 - i.f1 AS "150" FROM TIME_TBL t, INTERVAL_TBL i;
  
! SELECT t.f1 + i.f1 AS "180" FROM TIMETZ_TBL t, INTERVAL_TBL i;
! SELECT t.f1 - i.f1 AS "180" FROM TIMETZ_TBL t, INTERVAL_TBL i;
  
  -- SQL9x OVERLAPS operator
  -- test with time zone
***************
*** 239,249 ****
    FROM TEMP_TIMESTAMP
    ORDER BY "timestamp";
  
! SELECT '' AS "160", d.f1 AS "timestamp", t.f1 AS "interval", d.f1 + t.f1 AS plus
    FROM TEMP_TIMESTAMP d, INTERVAL_TBL t
    ORDER BY plus, "timestamp", "interval";
  
! SELECT '' AS "160", d.f1 AS "timestamp", t.f1 AS "interval", d.f1 - t.f1 AS minus
    FROM TEMP_TIMESTAMP d, INTERVAL_TBL t
    WHERE isfinite(d.f1)
    ORDER BY minus, "timestamp", "interval";
--- 239,249 ----
    FROM TEMP_TIMESTAMP
    ORDER BY "timestamp";
  
! SELECT '' AS "240", d.f1 AS "timestamp", t.f1 AS "interval", d.f1 + t.f1 AS plus
    FROM TEMP_TIMESTAMP d, INTERVAL_TBL t
    ORDER BY plus, "timestamp", "interval";
  
! SELECT '' AS "240", d.f1 AS "timestamp", t.f1 AS "interval", d.f1 - t.f1 AS minus
    FROM TEMP_TIMESTAMP d, INTERVAL_TBL t
    WHERE isfinite(d.f1)
    ORDER BY minus, "timestamp", "interval";
***************
*** 311,317 ****
  SELECT '' AS three, f1 as abstime, cast(f1 as timestamp) AS "timestamp"
    FROM ABSTIME_TBL WHERE NOT isfinite(f1);
  
! SELECT '' AS ten, f1 AS interval, reltime(f1) AS reltime
    FROM INTERVAL_TBL;
  
  SELECT '' AS six, f1 as reltime, CAST(f1 AS interval) AS interval
--- 311,317 ----
  SELECT '' AS three, f1 as abstime, cast(f1 as timestamp) AS "timestamp"
    FROM ABSTIME_TBL WHERE NOT isfinite(f1);
  
! SELECT '' AS fifteen, f1 AS interval, reltime(f1) AS reltime
    FROM INTERVAL_TBL;
  
  SELECT '' AS six, f1 as reltime, CAST(f1 AS interval) AS interval
Index: src/test/regress/sql/interval.sql
===================================================================
RCS file: /projects/cvsroot/pgsql/src/test/regress/sql/interval.sql,v
retrieving revision 1.9
diff -c -r1.9 interval.sql
*** src/test/regress/sql/interval.sql	6 Mar 2006 22:49:17 -0000	1.9
--- src/test/regress/sql/interval.sql	29 Aug 2006 14:42:38 -0000
***************
*** 25,30 ****
--- 25,35 ----
  INSERT INTO INTERVAL_TBL (f1) VALUES ('6 years');
  INSERT INTO INTERVAL_TBL (f1) VALUES ('5 months');
  INSERT INTO INTERVAL_TBL (f1) VALUES ('5 months 12 hours');
+ INSERT INTO INTERVAL_TBL (f1) VALUES ('41 mon');
+ INSERT INTO INTERVAL_TBL (f1) VALUES ('41 mon 360:00');
+ INSERT INTO INTERVAL_TBL (f1) VALUES ('41 mon -360:00');
+ INSERT INTO INTERVAL_TBL (f1) VALUES ('-41 mon 360:00');
+ INSERT INTO INTERVAL_TBL (f1) VALUES ('-41 mon -360:00');
  
  -- badly formatted interval
  INSERT INTO INTERVAL_TBL (f1) VALUES ('badly formatted interval');
***************
*** 32,65 ****
  
  -- test interval operators
  
! SELECT '' AS ten, * FROM INTERVAL_TBL;
  
! SELECT '' AS nine, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 <> interval '@ 10 days';
  
! SELECT '' AS three, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 <= interval '@ 5 hours';
  
! SELECT '' AS three, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 < interval '@ 1 day';
  
  SELECT '' AS one, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 = interval '@ 34 years';
  
! SELECT '' AS five, * FROM INTERVAL_TBL 
     WHERE INTERVAL_TBL.f1 >= interval '@ 1 month';
  
! SELECT '' AS nine, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 > interval '@ 3 seconds ago';
  
! SELECT '' AS fortyfive, r1.*, r2.*
     FROM INTERVAL_TBL r1, INTERVAL_TBL r2
     WHERE r1.f1 > r2.f1
     ORDER BY r1.f1, r2.f1;
  
  SET DATESTYLE = 'postgres';
  
! SELECT '' AS ten, * FROM INTERVAL_TBL;
  
  -- test avg(interval), which is somewhat fragile since people have been
  -- known to change the allowed input syntax for type interval without
--- 37,70 ----
  
  -- test interval operators
  
! SELECT '' AS fifteen, * FROM INTERVAL_TBL;
  
! SELECT '' AS fourteen, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 <> interval '@ 10 days';
  
! SELECT '' AS five, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 <= interval '@ 5 hours';
  
! SELECT '' AS five, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 < interval '@ 1 day';
  
  SELECT '' AS one, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 = interval '@ 34 years';
  
! SELECT '' AS eight, * FROM INTERVAL_TBL 
     WHERE INTERVAL_TBL.f1 >= interval '@ 1 month';
  
! SELECT '' AS twelve, * FROM INTERVAL_TBL
     WHERE INTERVAL_TBL.f1 > interval '@ 3 seconds ago';
  
! SELECT '' AS onehundredfive, r1.*, r2.*
     FROM INTERVAL_TBL r1, INTERVAL_TBL r2
     WHERE r1.f1 > r2.f1
     ORDER BY r1.f1, r2.f1;
  
  SET DATESTYLE = 'postgres';
  
! SELECT '' AS fifteen, * FROM INTERVAL_TBL;
  
  -- test avg(interval), which is somewhat fragile since people have been
  -- known to change the allowed input syntax for type interval without
***************
*** 67,72 ****
--- 72,87 ----
  
  select avg(f1) from interval_tbl;
  
+ 
+ -- Test interval division and multiplication
+ -- Ensures fractional months and days are handled properly
+ 
+ SELECT '' AS fourteen, f1 / 10 as quotient
+     FROM INTERVAL_TBL;
+ 
+ SELECT '' AS fourteen, f1 * 0.3 as product
+     FROM INTERVAL_TBL;
+ 
  -- test long interval input
  select '4 millenniums 5 centuries 4 decades 1 year 4 months 4 days 17 minutes 31 seconds'::interval;
  
