|
|
@ -43,7 +43,7 @@ SELECT date '1991-02-03' - time '04:05:06' AS "Subtract Time"; |
|
|
|
(1 row) |
|
|
|
(1 row) |
|
|
|
|
|
|
|
|
|
|
|
SELECT date '1991-02-03' - time with time zone '04:05:06 UTC' AS "Subtract Time UTC"; |
|
|
|
SELECT date '1991-02-03' - time with time zone '04:05:06 UTC' AS "Subtract Time UTC"; |
|
|
|
ERROR: Unable to identify an operator '-' for types 'date' and 'timetz' |
|
|
|
ERROR: Unable to identify an operator '-' for types 'date' and 'time with time zone' |
|
|
|
You will have to retype this query using an explicit cast |
|
|
|
You will have to retype this query using an explicit cast |
|
|
|
-- |
|
|
|
-- |
|
|
|
-- timestamp, interval arithmetic |
|
|
|
-- timestamp, interval arithmetic |
|
|
@ -118,9 +118,9 @@ SELECT interval '04:30' - time '01:02' AS "+03:28"; |
|
|
|
(1 row) |
|
|
|
(1 row) |
|
|
|
|
|
|
|
|
|
|
|
SELECT CAST(time with time zone '01:02-08' AS interval) AS "+00:01"; |
|
|
|
SELECT CAST(time with time zone '01:02-08' AS interval) AS "+00:01"; |
|
|
|
ERROR: Cannot cast type 'timetz' to 'interval' |
|
|
|
ERROR: Cannot cast type 'time with time zone' to 'interval' |
|
|
|
SELECT CAST(interval '02:03' AS time with time zone) AS "02:03:00-08"; |
|
|
|
SELECT CAST(interval '02:03' AS time with time zone) AS "02:03:00-08"; |
|
|
|
ERROR: Cannot cast type 'interval' to 'timetz' |
|
|
|
ERROR: Cannot cast type 'interval' to 'time with time zone' |
|
|
|
SELECT time with time zone '01:30-08' - interval '02:01' AS "23:29:00-08"; |
|
|
|
SELECT time with time zone '01:30-08' - interval '02:01' AS "23:29:00-08"; |
|
|
|
23:29:00-08 |
|
|
|
23:29:00-08 |
|
|
|
------------- |
|
|
|
------------- |
|
|
@ -153,7 +153,7 @@ SELECT CAST(date 'today' + time with time zone '03:30' |
|
|
|
(1 row) |
|
|
|
(1 row) |
|
|
|
|
|
|
|
|
|
|
|
SELECT interval '04:30' - time with time zone '01:02' AS "+03:28"; |
|
|
|
SELECT interval '04:30' - time with time zone '01:02' AS "+03:28"; |
|
|
|
ERROR: Unable to identify an operator '-' for types 'interval' and 'timetz' |
|
|
|
ERROR: Unable to identify an operator '-' for types 'interval' and 'time with time zone' |
|
|
|
You will have to retype this query using an explicit cast |
|
|
|
You will have to retype this query using an explicit cast |
|
|
|
-- We get 100 rows when run in GMT... |
|
|
|
-- We get 100 rows when run in GMT... |
|
|
|
SELECT t.d1 + i.f1 AS "102" FROM TIMESTAMP_TBL t, INTERVAL_TBL i |
|
|
|
SELECT t.d1 + i.f1 AS "102" FROM TIMESTAMP_TBL t, INTERVAL_TBL i |
|
|
|