--
-- Paths
--
-SET geqo TO 'off';
SELECT '' AS eight, npoints(f1) AS npoints, f1 AS path FROM PATH_TBL;
eight | npoints | path
-------+---------+---------------------------
| ((34,13),(40,15))
(8 rows)
-RESET geqo;
--
-- Polygons
--
--
-- Paths
--
-SET geqo TO 'off';
SELECT '' AS eight, npoints(f1) AS npoints, f1 AS path FROM PATH_TBL;
eight | npoints | path
-------+---------+---------------------------
| ((34,13),(40,15))
(8 rows)
-RESET geqo;
--
-- Polygons
--
--
-- Paths
--
-SET geqo TO 'off';
SELECT '' AS eight, npoints(f1) AS npoints, f1 AS path FROM PATH_TBL;
eight | npoints | path
-------+---------+---------------------------
| ((34,13),(40,15))
(8 rows)
-RESET geqo;
--
-- Polygons
--
| (5.1,34.5) | 34.8749193547455
(6 rows)
-SET geqo TO 'off';
SELECT '' AS thirtysix, p1.f1 AS point1, p2.f1 AS point2, p1.f1 <-> p2.f1 AS dist
FROM POINT_TBL p1, POINT_TBL p2
ORDER BY dist, p1.f1[0], p2.f1[0];
| (5.1,34.5) | (10,10) | 24.9851956166046
(3 rows)
-RESET geqo;
| ["Wed Dec 31 16:00:00 1969 PST" "Mon May 01 00:30:30 1995 PDT"]
(3 rows)
-SET geqo TO 'off';
SELECT '' AS five, t1.f1, t2.f1
FROM TINTERVAL_TBL t1, TINTERVAL_TBL t2
WHERE t1.f1 && t2.f1 and
| ["Wed Dec 31 16:00:00 1969 PST" "Mon May 01 00:30:30 1995 PDT"]
(3 rows)
-RESET geqo;
-- Paths
--
-SET geqo TO 'off';
-
SELECT '' AS eight, npoints(f1) AS npoints, f1 AS path FROM PATH_TBL;
SELECT '' AS four, path(f1) FROM POLYGON_TBL;
SELECT '' AS eight, p1.f1 * point '(2,-1)' AS dist_mul
FROM PATH_TBL p1;
-RESET geqo;
-
--
-- Polygons
--
FROM POINT_TBL p
ORDER BY dist;
-SET geqo TO 'off';
-
SELECT '' AS thirtysix, p1.f1 AS point1, p2.f1 AS point2, p1.f1 <-> p2.f1 AS dist
FROM POINT_TBL p1, POINT_TBL p2
ORDER BY dist, p1.f1[0], p2.f1[0];
FROM POINT_TBL p1, POINT_TBL p2
WHERE (p1.f1 <-> p2.f1) > 3 and p1.f1 << p2.f1 and p1.f1 >^ p2.f1
ORDER BY distance;
-
-RESET geqo;
-
WHERE t1.f1 &&
tinterval '["Aug 15 14:23:19 1983" "Sep 16 14:23:19 1983"]';
-SET geqo TO 'off';
-
SELECT '' AS five, t1.f1, t2.f1
FROM TINTERVAL_TBL t1, TINTERVAL_TBL t2
WHERE t1.f1 && t2.f1 and
(abstime 'Aug 15 14:23:19 1983' <#>
abstime 'Sep 16 14:23:19 1983')
ORDER BY t1.f1;
-
-RESET geqo;