diff --git a/src/test/regress/expected/aggregates.out b/src/test/regress/expected/aggregates.out index 5dac6162b5..c0829b898b 100644 --- a/src/test/regress/expected/aggregates.out +++ b/src/test/regress/expected/aggregates.out @@ -1,132 +1,135 @@ -QUERY: SELECT avg(four) AS avg_1 FROM onek; -avg_1 ------ - 1 -(1 row) - -QUERY: SELECT avg(a) AS avg_32 FROM aggtest WHERE a < 100; -avg_32 ------- - 32 -(1 row) - -QUERY: SELECT avg(b) AS avg_107_943 FROM aggtest; -avg_107_943 ------------ - 107.943 -(1 row) - -QUERY: SELECT avg(gpa) AS avg_3_4 FROM student; -avg_3_4 +-- +-- AGGREGATES +-- +SELECT avg(four) AS avg_1 FROM onek; + avg_1 ------- - 3.4 + 1 (1 row) -QUERY: SELECT sum(four) AS sum_1500 FROM onek; -sum_1500 +SELECT avg(a) AS avg_32 FROM aggtest WHERE a < 100; + avg_32 -------- - 1500 + 32 (1 row) -QUERY: SELECT sum(a) AS sum_198 FROM aggtest; -sum_198 -------- - 198 +SELECT avg(b) AS avg_107_943 FROM aggtest; + avg_107_943 +------------- + 107.943 (1 row) -QUERY: SELECT sum(b) AS avg_431_773 FROM aggtest; -avg_431_773 ------------ - 431.773 +SELECT avg(gpa) AS avg_3_4 FROM student; + avg_3_4 +--------- + 3.4 (1 row) -QUERY: SELECT sum(gpa) AS avg_6_8 FROM student; -avg_6_8 -------- - 6.8 -(1 row) - -QUERY: SELECT max(four) AS max_3 FROM onek; -max_3 ------ - 3 -(1 row) - -QUERY: SELECT max(a) AS max_100 FROM aggtest; -max_100 -------- - 100 -(1 row) - -QUERY: SELECT max(aggtest.b) AS max_324_78 FROM aggtest; -max_324_78 +SELECT sum(four) AS sum_1500 FROM onek; + sum_1500 ---------- - 324.78 + 1500 (1 row) -QUERY: SELECT max(student.gpa) AS max_3_7 FROM student; -max_3_7 +SELECT sum(a) AS sum_198 FROM aggtest; + sum_198 +--------- + 198 +(1 row) + +SELECT sum(b) AS avg_431_773 FROM aggtest; + avg_431_773 +------------- + 431.773 +(1 row) + +SELECT sum(gpa) AS avg_6_8 FROM student; + avg_6_8 +--------- + 6.8 +(1 row) + +SELECT max(four) AS max_3 FROM onek; + max_3 ------- - 3.7 + 3 (1 row) -QUERY: SELECT count(four) AS cnt_1000 FROM onek; -cnt_1000 --------- - 1000 +SELECT max(a) AS max_100 FROM aggtest; + max_100 +--------- + 100 (1 row) -QUERY: SELECT count(DISTINCT four) AS cnt_4 FROM onek; -cnt_4 ------ - 4 +SELECT max(aggtest.b) AS max_324_78 FROM aggtest; + max_324_78 +------------ + 324.78 (1 row) -QUERY: select ten, count(*), sum(four) from onek group by ten; -ten|count|sum ----+-----+--- - 0| 100|100 - 1| 100|200 - 2| 100|100 - 3| 100|200 - 4| 100|100 - 5| 100|200 - 6| 100|100 - 7| 100|200 - 8| 100|100 - 9| 100|200 +SELECT max(student.gpa) AS max_3_7 FROM student; + max_3_7 +--------- + 3.7 +(1 row) + +SELECT count(four) AS cnt_1000 FROM onek; + cnt_1000 +---------- + 1000 +(1 row) + +SELECT count(DISTINCT four) AS cnt_4 FROM onek; + cnt_4 +------- + 4 +(1 row) + +select ten, count(*), sum(four) from onek group by ten; + ten | count | sum +-----+-------+----- + 0 | 100 | 100 + 1 | 100 | 200 + 2 | 100 | 100 + 3 | 100 | 200 + 4 | 100 | 100 + 5 | 100 | 200 + 6 | 100 | 100 + 7 | 100 | 200 + 8 | 100 | 100 + 9 | 100 | 200 (10 rows) -QUERY: select ten, count(four), sum(DISTINCT four) from onek group by ten; -ten|count|sum ----+-----+--- - 0| 100| 2 - 1| 100| 4 - 2| 100| 2 - 3| 100| 4 - 4| 100| 2 - 5| 100| 4 - 6| 100| 2 - 7| 100| 4 - 8| 100| 2 - 9| 100| 4 +select ten, count(four), sum(DISTINCT four) from onek group by ten; + ten | count | sum +-----+-------+----- + 0 | 100 | 2 + 1 | 100 | 4 + 2 | 100 | 2 + 3 | 100 | 4 + 4 | 100 | 2 + 5 | 100 | 4 + 6 | 100 | 2 + 7 | 100 | 4 + 8 | 100 | 2 + 9 | 100 | 4 (10 rows) -QUERY: SELECT newavg(four) AS avg_1 FROM onek; -avg_1 ------ - 1 +SELECT newavg(four) AS avg_1 FROM onek; + avg_1 +------- + 1 (1 row) -QUERY: SELECT newsum(four) AS sum_1500 FROM onek; -sum_1500 --------- - 1500 +SELECT newsum(four) AS sum_1500 FROM onek; + sum_1500 +---------- + 1500 (1 row) -QUERY: SELECT newcnt(four) AS cnt_1000 FROM onek; -cnt_1000 --------- - 1000 +SELECT newcnt(four) AS cnt_1000 FROM onek; + cnt_1000 +---------- + 1000 (1 row) diff --git a/src/test/regress/expected/alter_table.out b/src/test/regress/expected/alter_table.out index 1c244df734..b4eff9499d 100644 --- a/src/test/regress/expected/alter_table.out +++ b/src/test/regress/expected/alter_table.out @@ -1,253 +1,268 @@ -QUERY: CREATE TABLE tmp (initial int4); -QUERY: ALTER TABLE tmp ADD COLUMN a int4; -QUERY: ALTER TABLE tmp ADD COLUMN b name; -QUERY: ALTER TABLE tmp ADD COLUMN c text; -QUERY: ALTER TABLE tmp ADD COLUMN d float8; -QUERY: ALTER TABLE tmp ADD COLUMN e float4; -QUERY: ALTER TABLE tmp ADD COLUMN f int2; -QUERY: ALTER TABLE tmp ADD COLUMN g polygon; -QUERY: ALTER TABLE tmp ADD COLUMN h abstime; -QUERY: ALTER TABLE tmp ADD COLUMN i char; -QUERY: ALTER TABLE tmp ADD COLUMN j abstime[]; -QUERY: ALTER TABLE tmp ADD COLUMN k dt; +-- +-- ALTER_TABLE +-- add attribute +-- +CREATE TABLE tmp (initial int4); +ALTER TABLE tmp ADD COLUMN a int4; +ALTER TABLE tmp ADD COLUMN b name; +ALTER TABLE tmp ADD COLUMN c text; +ALTER TABLE tmp ADD COLUMN d float8; +ALTER TABLE tmp ADD COLUMN e float4; +ALTER TABLE tmp ADD COLUMN f int2; +ALTER TABLE tmp ADD COLUMN g polygon; +ALTER TABLE tmp ADD COLUMN h abstime; +ALTER TABLE tmp ADD COLUMN i char; +ALTER TABLE tmp ADD COLUMN j abstime[]; +ALTER TABLE tmp ADD COLUMN k dt; ERROR: Unable to locate type name 'dt' in catalog -QUERY: ALTER TABLE tmp ADD COLUMN l tid; -QUERY: ALTER TABLE tmp ADD COLUMN m xid; -QUERY: ALTER TABLE tmp ADD COLUMN n oid8; -QUERY: ALTER TABLE tmp ADD COLUMN p smgr; -QUERY: ALTER TABLE tmp ADD COLUMN q point; -QUERY: ALTER TABLE tmp ADD COLUMN r lseg; -QUERY: ALTER TABLE tmp ADD COLUMN s path; -QUERY: ALTER TABLE tmp ADD COLUMN t box; -QUERY: ALTER TABLE tmp ADD COLUMN u tinterval; -QUERY: ALTER TABLE tmp ADD COLUMN v datetime; -QUERY: ALTER TABLE tmp ADD COLUMN w timespan; -QUERY: ALTER TABLE tmp ADD COLUMN x float8[]; -QUERY: ALTER TABLE tmp ADD COLUMN y float4[]; -QUERY: ALTER TABLE tmp ADD COLUMN z int2[]; -QUERY: INSERT INTO tmp (a, b, c, d, e, f, g, h, i, j, k, l, m, n, p, q, r, s, t, u, +ALTER TABLE tmp ADD COLUMN l tid; +ALTER TABLE tmp ADD COLUMN m xid; +ALTER TABLE tmp ADD COLUMN n oid8; +--ALTER TABLE tmp ADD COLUMN o lock; +ALTER TABLE tmp ADD COLUMN p smgr; +ALTER TABLE tmp ADD COLUMN q point; +ALTER TABLE tmp ADD COLUMN r lseg; +ALTER TABLE tmp ADD COLUMN s path; +ALTER TABLE tmp ADD COLUMN t box; +ALTER TABLE tmp ADD COLUMN u tinterval; +ALTER TABLE tmp ADD COLUMN v datetime; +ALTER TABLE tmp ADD COLUMN w timespan; +ALTER TABLE tmp ADD COLUMN x float8[]; +ALTER TABLE tmp ADD COLUMN y float4[]; +ALTER TABLE tmp ADD COLUMN z int2[]; +INSERT INTO tmp (a, b, c, d, e, f, g, h, i, j, k, l, m, n, p, q, r, s, t, u, v, w, x, y, z) - VALUES (4, 'name', 'text', 4.1, 4.1, 2, '(4.1,4.1,3.1,3.1)', - 'Mon May 1 00:30:30 1995', 'c', '{Mon May 1 00:30:30 1995, Monday Aug 24 14:43:07 1992, epoch}', + VALUES (4, 'name', 'text', 4.1, 4.1, 2, '(4.1,4.1,3.1,3.1)', + 'Mon May 1 00:30:30 1995', 'c', '{Mon May 1 00:30:30 1995, Monday Aug 24 14:43:07 1992, epoch}', 314159, '(1,1)', 512, '1 2 3 4 5 6 7 8', 'magnetic disk', '(1.1,1.1)', '(4.1,4.1,3.1,3.1)', '(0,2,4.1,4.1,3.1,3.1)', '(4.1,4.1,3.1,3.1)', '["current" "infinity"]', '1/3', '1,name', '{1.0,2.0,3.0,4.0}', '{1.0,2.0,3.0,4.0}', '{1,2,3,4}'); ERROR: Relation 'tmp' does not have attribute 'k' -QUERY: SELECT * FROM tmp; -initial|a|b|c|d|e|f|g|h|i|j|l|m|n|p|q|r|s|t|u|v|w|x|y|z --------+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- +SELECT * FROM tmp; + initial | a | b | c | d | e | f | g | h | i | j | l | m | n | p | q | r | s | t | u | v | w | x | y | z +---------+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+--- (0 rows) -QUERY: DROP TABLE tmp; -QUERY: CREATE TABLE tmp ( +DROP TABLE tmp; +-- the wolf bug - schema mods caused inconsistent row descriptors +CREATE TABLE tmp ( initial int4 ); -QUERY: ALTER TABLE tmp ADD COLUMN a int4; -QUERY: ALTER TABLE tmp ADD COLUMN b name; -QUERY: ALTER TABLE tmp ADD COLUMN c text; -QUERY: ALTER TABLE tmp ADD COLUMN d float8; -QUERY: ALTER TABLE tmp ADD COLUMN e float4; -QUERY: ALTER TABLE tmp ADD COLUMN f int2; -QUERY: ALTER TABLE tmp ADD COLUMN g polygon; -QUERY: ALTER TABLE tmp ADD COLUMN h abstime; -QUERY: ALTER TABLE tmp ADD COLUMN i char; -QUERY: ALTER TABLE tmp ADD COLUMN j abstime[]; -QUERY: ALTER TABLE tmp ADD COLUMN k dt; +ALTER TABLE tmp ADD COLUMN a int4; +ALTER TABLE tmp ADD COLUMN b name; +ALTER TABLE tmp ADD COLUMN c text; +ALTER TABLE tmp ADD COLUMN d float8; +ALTER TABLE tmp ADD COLUMN e float4; +ALTER TABLE tmp ADD COLUMN f int2; +ALTER TABLE tmp ADD COLUMN g polygon; +ALTER TABLE tmp ADD COLUMN h abstime; +ALTER TABLE tmp ADD COLUMN i char; +ALTER TABLE tmp ADD COLUMN j abstime[]; +ALTER TABLE tmp ADD COLUMN k dt; ERROR: Unable to locate type name 'dt' in catalog -QUERY: ALTER TABLE tmp ADD COLUMN l tid; -QUERY: ALTER TABLE tmp ADD COLUMN m xid; -QUERY: ALTER TABLE tmp ADD COLUMN n oid8; -QUERY: ALTER TABLE tmp ADD COLUMN p smgr; -QUERY: ALTER TABLE tmp ADD COLUMN q point; -QUERY: ALTER TABLE tmp ADD COLUMN r lseg; -QUERY: ALTER TABLE tmp ADD COLUMN s path; -QUERY: ALTER TABLE tmp ADD COLUMN t box; -QUERY: ALTER TABLE tmp ADD COLUMN u tinterval; -QUERY: ALTER TABLE tmp ADD COLUMN v datetime; -QUERY: ALTER TABLE tmp ADD COLUMN w timespan; -QUERY: ALTER TABLE tmp ADD COLUMN x float8[]; -QUERY: ALTER TABLE tmp ADD COLUMN y float4[]; -QUERY: ALTER TABLE tmp ADD COLUMN z int2[]; -QUERY: INSERT INTO tmp (a, b, c, d, e, f, g, h, i, j, k, l, m, n, p, q, r, s, t, u, +ALTER TABLE tmp ADD COLUMN l tid; +ALTER TABLE tmp ADD COLUMN m xid; +ALTER TABLE tmp ADD COLUMN n oid8; +--ALTER TABLE tmp ADD COLUMN o lock; +ALTER TABLE tmp ADD COLUMN p smgr; +ALTER TABLE tmp ADD COLUMN q point; +ALTER TABLE tmp ADD COLUMN r lseg; +ALTER TABLE tmp ADD COLUMN s path; +ALTER TABLE tmp ADD COLUMN t box; +ALTER TABLE tmp ADD COLUMN u tinterval; +ALTER TABLE tmp ADD COLUMN v datetime; +ALTER TABLE tmp ADD COLUMN w timespan; +ALTER TABLE tmp ADD COLUMN x float8[]; +ALTER TABLE tmp ADD COLUMN y float4[]; +ALTER TABLE tmp ADD COLUMN z int2[]; +INSERT INTO tmp (a, b, c, d, e, f, g, h, i, j, k, l, m, n, p, q, r, s, t, u, v, w, x, y, z) - VALUES (4, 'name', 'text', 4.1, 4.1, 2, '(4.1,4.1,3.1,3.1)', + VALUES (4, 'name', 'text', 4.1, 4.1, 2, '(4.1,4.1,3.1,3.1)', 'Mon May 1 00:30:30 1995', 'c', '{Mon May 1 00:30:30 1995, Monday Aug 24 14:43:07 1992, epoch}', 314159, '(1,1)', 512, '1 2 3 4 5 6 7 8', 'magnetic disk', '(1.1,1.1)', '(4.1,4.1,3.1,3.1)', '(0,2,4.1,4.1,3.1,3.1)', '(4.1,4.1,3.1,3.1)', '["current" "infinity"]', '1/3', '1,name', '{1.0,2.0,3.0,4.0}', '{1.0,2.0,3.0,4.0}', '{1,2,3,4}'); ERROR: Relation 'tmp' does not have attribute 'k' -QUERY: SELECT * FROM tmp; -initial|a|b|c|d|e|f|g|h|i|j|l|m|n|p|q|r|s|t|u|v|w|x|y|z --------+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- +SELECT * FROM tmp; + initial | a | b | c | d | e | f | g | h | i | j | l | m | n | p | q | r | s | t | u | v | w | x | y | z +---------+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+--- (0 rows) -QUERY: DROP TABLE tmp; -QUERY: ALTER TABLE tenk1 RENAME TO ten_k; -QUERY: SELECT unique1 FROM ten_k WHERE unique1 < 20; -unique1 -------- - 0 - 1 - 2 - 3 - 4 - 5 - 6 - 7 - 8 - 9 - 10 - 11 - 12 - 13 - 14 - 15 - 16 - 17 - 18 - 19 +DROP TABLE tmp; +-- +-- rename - +-- should preserve indices +-- +ALTER TABLE tenk1 RENAME TO ten_k; +-- 20 values, sorted +SELECT unique1 FROM ten_k WHERE unique1 < 20; + unique1 +--------- + 0 + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 (20 rows) -QUERY: SELECT unique2 FROM ten_k WHERE unique2 < 20; -unique2 -------- - 0 - 1 - 2 - 3 - 4 - 5 - 6 - 7 - 8 - 9 - 10 - 11 - 12 - 13 - 14 - 15 - 16 - 17 - 18 - 19 +-- 20 values, sorted +SELECT unique2 FROM ten_k WHERE unique2 < 20; + unique2 +--------- + 0 + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 (20 rows) -QUERY: SELECT hundred FROM ten_k WHERE hundred = 50; -hundred -------- - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 - 50 +-- 100 values, sorted +SELECT hundred FROM ten_k WHERE hundred = 50; + hundred +--------- + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 + 50 (100 rows) -QUERY: ALTER TABLE ten_k RENAME TO tenk1; -QUERY: SELECT unique1 FROM tenk1 WHERE unique1 < 5; -unique1 -------- - 0 - 1 - 2 - 3 - 4 +ALTER TABLE ten_k RENAME TO tenk1; +-- 5 values, sorted +SELECT unique1 FROM tenk1 WHERE unique1 < 5; + unique1 +--------- + 0 + 1 + 2 + 3 + 4 (5 rows) diff --git a/src/test/regress/expected/btree_index.out b/src/test/regress/expected/btree_index.out index fae68fd164..cedb7e7ec2 100644 --- a/src/test/regress/expected/btree_index.out +++ b/src/test/regress/expected/btree_index.out @@ -1,96 +1,100 @@ -QUERY: SELECT b.* +-- +-- BTREE_INDEX +-- test retrieval of min/max keys for each index +-- +SELECT b.* FROM bt_i4_heap b WHERE b.seqno < 1; -seqno| random ------+---------- - 0|1935401906 + seqno | random +-------+------------ + 0 | 1935401906 (1 row) -QUERY: SELECT b.* +SELECT b.* FROM bt_i4_heap b WHERE b.seqno >= 9999; -seqno| random ------+---------- - 9999|1227676208 + seqno | random +-------+------------ + 9999 | 1227676208 (1 row) -QUERY: SELECT b.* +SELECT b.* FROM bt_i4_heap b WHERE b.seqno = 4500; -seqno| random ------+---------- - 4500|2080851358 + seqno | random +-------+------------ + 4500 | 2080851358 (1 row) -QUERY: SELECT b.* +SELECT b.* FROM bt_name_heap b WHERE b.seqno < '1'::name; -seqno| random ------+---------- - 0|1935401906 + seqno | random +-------+------------ + 0 | 1935401906 (1 row) -QUERY: SELECT b.* +SELECT b.* FROM bt_name_heap b WHERE b.seqno >= '9999'::name; -seqno| random ------+---------- - 9999|1227676208 + seqno | random +-------+------------ + 9999 | 1227676208 (1 row) -QUERY: SELECT b.* +SELECT b.* FROM bt_name_heap b WHERE b.seqno = '4500'::name; -seqno| random ------+---------- - 4500|2080851358 + seqno | random +-------+------------ + 4500 | 2080851358 (1 row) -QUERY: SELECT b.* +SELECT b.* FROM bt_txt_heap b WHERE b.seqno < '1'::text; -seqno| random ------+---------- - 0|1935401906 + seqno | random +-------+------------ + 0 | 1935401906 (1 row) -QUERY: SELECT b.* +SELECT b.* FROM bt_txt_heap b WHERE b.seqno >= '9999'::text; -seqno| random ------+---------- - 9999|1227676208 + seqno | random +-------+------------ + 9999 | 1227676208 (1 row) -QUERY: SELECT b.* +SELECT b.* FROM bt_txt_heap b WHERE b.seqno = '4500'::text; -seqno| random ------+---------- - 4500|2080851358 + seqno | random +-------+------------ + 4500 | 2080851358 (1 row) -QUERY: SELECT b.* +SELECT b.* FROM bt_f8_heap b WHERE b.seqno < '1'::float8; -seqno| random ------+---------- - 0|1935401906 + seqno | random +-------+------------ + 0 | 1935401906 (1 row) -QUERY: SELECT b.* +SELECT b.* FROM bt_f8_heap b WHERE b.seqno >= '9999'::float8; -seqno| random ------+---------- - 9999|1227676208 + seqno | random +-------+------------ + 9999 | 1227676208 (1 row) -QUERY: SELECT b.* +SELECT b.* FROM bt_f8_heap b WHERE b.seqno = '4500'::float8; -seqno| random ------+---------- - 4500|2080851358 + seqno | random +-------+------------ + 4500 | 2080851358 (1 row) diff --git a/src/test/regress/expected/hash_index.out b/src/test/regress/expected/hash_index.out index ee3f615beb..db687e5a24 100644 --- a/src/test/regress/expected/hash_index.out +++ b/src/test/regress/expected/hash_index.out @@ -1,139 +1,198 @@ -QUERY: SELECT hash_i4_heap.* +-- +-- HASH_INDEX +-- grep 843938989 hash.data +-- +SELECT hash_i4_heap.* WHERE hash_i4_heap.random = 843938989; -seqno| random ------+--------- - 15|843938989 + seqno | random +-------+----------- + 15 | 843938989 (1 row) -QUERY: SELECT hash_i4_heap.* +-- +-- hash index +-- grep 66766766 hash.data +-- +SELECT hash_i4_heap.* WHERE hash_i4_heap.random = 66766766; -seqno|random ------+------ + seqno | random +-------+-------- (0 rows) -QUERY: SELECT hash_name_heap.* +-- +-- hash index +-- grep 1505703298 hash.data +-- +SELECT hash_name_heap.* WHERE hash_name_heap.random = '1505703298'::name; -seqno| random ------+---------- - 9838|1505703298 + seqno | random +-------+------------ + 9838 | 1505703298 (1 row) -QUERY: SELECT hash_name_heap.* +-- +-- hash index +-- grep 7777777 hash.data +-- +SELECT hash_name_heap.* WHERE hash_name_heap.random = '7777777'::name; -seqno|random ------+------ + seqno | random +-------+-------- (0 rows) -QUERY: SELECT hash_txt_heap.* +-- +-- hash index +-- grep 1351610853 hash.data +-- +SELECT hash_txt_heap.* WHERE hash_txt_heap.random = '1351610853'::text; -seqno| random ------+---------- - 5677|1351610853 + seqno | random +-------+------------ + 5677 | 1351610853 (1 row) -QUERY: SELECT hash_txt_heap.* +-- +-- hash index +-- grep 111111112222222233333333 hash.data +-- +SELECT hash_txt_heap.* WHERE hash_txt_heap.random = '111111112222222233333333'::text; -seqno|random ------+------ + seqno | random +-------+-------- (0 rows) -QUERY: SELECT hash_f8_heap.* +-- +-- hash index +-- grep 444705537 hash.data +-- +SELECT hash_f8_heap.* WHERE hash_f8_heap.random = '444705537'::float8; -seqno| random ------+--------- - 7853|444705537 + seqno | random +-------+----------- + 7853 | 444705537 (1 row) -QUERY: SELECT hash_f8_heap.* +-- +-- hash index +-- grep 88888888 hash.data +-- +SELECT hash_f8_heap.* WHERE hash_f8_heap.random = '88888888'::float8; -seqno|random ------+------ + seqno | random +-------+-------- (0 rows) -QUERY: UPDATE hash_i4_heap +-- +-- hash index +-- grep '^90[^0-9]' hashovfl.data +-- +-- SELECT count(*) AS i988 FROM hash_ovfl_heap +-- WHERE x = 90; +-- +-- hash index +-- grep '^1000[^0-9]' hashovfl.data +-- +-- SELECT count(*) AS i0 FROM hash_ovfl_heap +-- WHERE x = 1000; +-- +-- HASH +-- +UPDATE hash_i4_heap SET random = 1 WHERE hash_i4_heap.seqno = 1492; -QUERY: SELECT h.seqno AS i1492, h.random AS i1 +SELECT h.seqno AS i1492, h.random AS i1 FROM hash_i4_heap h WHERE h.random = 1; -i1492|i1 ------+-- - 1492| 1 + i1492 | i1 +-------+---- + 1492 | 1 (1 row) -QUERY: UPDATE hash_i4_heap - SET seqno = 20000 +UPDATE hash_i4_heap + SET seqno = 20000 WHERE hash_i4_heap.random = 1492795354; -QUERY: SELECT h.seqno AS i20000 +SELECT h.seqno AS i20000 FROM hash_i4_heap h WHERE h.random = 1492795354; -i20000 ------- - 20000 + i20000 +-------- + 20000 (1 row) -QUERY: UPDATE hash_name_heap +UPDATE hash_name_heap SET random = '0123456789abcdef'::name WHERE hash_name_heap.seqno = 6543; -QUERY: SELECT h.seqno AS i6543, h.random AS c0_to_f +SELECT h.seqno AS i6543, h.random AS c0_to_f FROM hash_name_heap h WHERE h.random = '0123456789abcdef'::name; -i6543|c0_to_f ------+---------------- - 6543|0123456789abcdef + i6543 | c0_to_f +-------+------------------ + 6543 | 0123456789abcdef (1 row) -QUERY: UPDATE hash_name_heap +UPDATE hash_name_heap SET seqno = 20000 WHERE hash_name_heap.random = '76652222'::name; -QUERY: SELECT h.seqno AS emptyset +-- +-- this is the row we just replaced; index scan should return zero rows +-- +SELECT h.seqno AS emptyset FROM hash_name_heap h WHERE h.random = '76652222'::name; -emptyset --------- + emptyset +---------- (0 rows) -QUERY: UPDATE hash_txt_heap +UPDATE hash_txt_heap SET random = '0123456789abcdefghijklmnop'::text WHERE hash_txt_heap.seqno = 4002; -QUERY: SELECT h.seqno AS i4002, h.random AS c0_to_p +SELECT h.seqno AS i4002, h.random AS c0_to_p FROM hash_txt_heap h WHERE h.random = '0123456789abcdefghijklmnop'::text; -i4002|c0_to_p ------+-------------------------- - 4002|0123456789abcdefghijklmnop + i4002 | c0_to_p +-------+---------------------------- + 4002 | 0123456789abcdefghijklmnop (1 row) -QUERY: UPDATE hash_txt_heap +UPDATE hash_txt_heap SET seqno = 20000 WHERE hash_txt_heap.random = '959363399'::text; -QUERY: SELECT h.seqno AS t20000 +SELECT h.seqno AS t20000 FROM hash_txt_heap h WHERE h.random = '959363399'::text; -t20000 ------- - 20000 + t20000 +-------- + 20000 (1 row) -QUERY: UPDATE hash_f8_heap +UPDATE hash_f8_heap SET random = '-1234.1234'::float8 WHERE hash_f8_heap.seqno = 8906; -QUERY: SELECT h.seqno AS i8096, h.random AS f1234_1234 +SELECT h.seqno AS i8096, h.random AS f1234_1234 FROM hash_f8_heap h WHERE h.random = '-1234.1234'::float8; -i8096|f1234_1234 ------+---------- - 8906|-1234.1234 + i8096 | f1234_1234 +-------+------------ + 8906 | -1234.1234 (1 row) -QUERY: UPDATE hash_f8_heap +UPDATE hash_f8_heap SET seqno = 20000 WHERE hash_f8_heap.random = '488912369'::float8; -QUERY: SELECT h.seqno AS f20000 +SELECT h.seqno AS f20000 FROM hash_f8_heap h WHERE h.random = '488912369'::float8; -f20000 ------- - 20000 + f20000 +-------- + 20000 (1 row) +-- UPDATE hash_ovfl_heap +-- SET x = 1000 +-- WHERE x = 90; +-- this vacuums the index as well +-- VACUUM hash_ovfl_heap; +-- SELECT count(*) AS i0 FROM hash_ovfl_heap +-- WHERE x = 90; +-- SELECT count(*) AS i988 FROM hash_ovfl_heap +-- WHERE x = 1000; diff --git a/src/test/regress/expected/join.out b/src/test/regress/expected/join.out index 17bf7c6a51..1245847a96 100644 --- a/src/test/regress/expected/join.out +++ b/src/test/regress/expected/join.out @@ -1,94 +1,152 @@ -QUERY: CREATE TABLE JOIN_TBL ( +-- +-- JOIN +-- Test join clauses +-- +CREATE TABLE JOIN1_TBL ( i integer, j integer, - x text + t text ); -QUERY: CREATE TABLE JOIN2_TBL ( +CREATE TABLE JOIN2_TBL ( i integer, k integer ); -QUERY: INSERT INTO JOIN_TBL VALUES (1, 3, 'one'); -QUERY: INSERT INTO JOIN_TBL VALUES (2, 2, 'two'); -QUERY: INSERT INTO JOIN_TBL VALUES (3, 1, 'three'); -QUERY: INSERT INTO JOIN_TBL VALUES (4, 0, 'four'); -QUERY: INSERT INTO JOIN2_TBL VALUES (1, -1); -QUERY: INSERT INTO JOIN2_TBL VALUES (2, 2); -QUERY: INSERT INTO JOIN2_TBL VALUES (3, -3); -QUERY: INSERT INTO JOIN2_TBL VALUES (2, 4); -QUERY: SELECT '' AS "xxx", * - FROM JOIN_TBL CROSS JOIN JOIN2_TBL; -xxx|i|j|x |i| k ----+-+-+-----+-+-- - |1|3|one |1|-1 - |2|2|two |1|-1 - |3|1|three|1|-1 - |4|0|four |1|-1 - |1|3|one |2| 2 - |2|2|two |2| 2 - |3|1|three|2| 2 - |4|0|four |2| 2 - |1|3|one |3|-3 - |2|2|two |3|-3 - |3|1|three|3|-3 - |4|0|four |3|-3 - |1|3|one |2| 4 - |2|2|two |2| 4 - |3|1|three|2| 4 - |4|0|four |2| 4 +CREATE TABLE JOIN3_TBL ( + i integer, + j integer, + y integer +); +CREATE TABLE JOIN4_TBL ( + k integer, + z integer +); +INSERT INTO JOIN1_TBL VALUES (1, 3, 'one'); +INSERT INTO JOIN1_TBL VALUES (2, 2, 'two'); +INSERT INTO JOIN1_TBL VALUES (3, 1, 'three'); +INSERT INTO JOIN1_TBL VALUES (4, 0, 'four'); +INSERT INTO JOIN2_TBL VALUES (1, -1); +INSERT INTO JOIN2_TBL VALUES (2, 2); +INSERT INTO JOIN2_TBL VALUES (3, -3); +INSERT INTO JOIN2_TBL VALUES (2, 4); +-- +-- CROSS JOIN +-- Qualifications are not allowed on cross joins, +-- which degenerate into a standard unqualified inner join. +-- +SELECT '' AS "xxx", * + FROM JOIN1_TBL CROSS JOIN JOIN2_TBL; + xxx | i | j | t | i | k +-----+---+---+-------+---+---- + | 1 | 3 | one | 1 | -1 + | 2 | 2 | two | 1 | -1 + | 3 | 1 | three | 1 | -1 + | 4 | 0 | four | 1 | -1 + | 1 | 3 | one | 2 | 2 + | 2 | 2 | two | 2 | 2 + | 3 | 1 | three | 2 | 2 + | 4 | 0 | four | 2 | 2 + | 1 | 3 | one | 3 | -3 + | 2 | 2 | two | 3 | -3 + | 3 | 1 | three | 3 | -3 + | 4 | 0 | four | 3 | -3 + | 1 | 3 | one | 2 | 4 + | 2 | 2 | two | 2 | 4 + | 3 | 1 | three | 2 | 4 + | 4 | 0 | four | 2 | 4 (16 rows) -QUERY: SELECT '' AS "xxx", * - FROM JOIN_TBL NATURAL JOIN JOIN2_TBL; +SELECT '' AS "xxx", i, k, t + FROM JOIN1_TBL CROSS JOIN JOIN2_TBL; +ERROR: Column 'i' is ambiguous +SELECT '' AS "xxx", ii, tt, kk + FROM JOIN1_TBL CROSS JOIN JOIN2_TBL AS JT (ii, jj, tt, ii2, kk); +ERROR: parser: parse error at or near "(" +SELECT '' AS "xxx", jt.ii, jt.jj, jt.kk + FROM JOIN1_TBL CROSS JOIN JOIN2_TBL AS JT (ii, jj, tt, ii2, kk); +ERROR: parser: parse error at or near "(" +-- +-- +-- Inner joins (equi-joins) +-- +-- +-- +-- Inner joins (equi-joins) with USING clause +-- The USING syntax changes the shape of the resulting table +-- by including a column in the USING clause only once in the result. +-- +-- Inner equi-join on all columns with the same name +SELECT '' AS "xxx", * + FROM JOIN1_TBL NATURAL JOIN JOIN2_TBL; ERROR: JOIN expressions are not yet implemented -QUERY: SELECT '' AS "xxx", * - FROM JOIN_TBL INNER JOIN JOIN2_TBL USING (i); +-- Inner equi-join on specified column +SELECT '' AS "xxx", * + FROM JOIN1_TBL INNER JOIN JOIN2_TBL USING (i); ERROR: JOIN expressions are not yet implemented -QUERY: SELECT '' AS "xxx", * - FROM JOIN_TBL JOIN JOIN2_TBL ON (JOIN_TBL.i = JOIN2_TBL.i); +-- Same as above, slightly different syntax +SELECT '' AS "xxx", * + FROM JOIN1_TBL JOIN JOIN2_TBL USING (i); ERROR: JOIN expressions are not yet implemented -QUERY: SELECT '' AS "xxx", * - FROM JOIN_TBL JOIN JOIN2_TBL ON (JOIN_TBL.i = JOIN2_TBL.k); +-- +-- Inner joins (equi-joins) +-- +SELECT '' AS "xxx", * + FROM JOIN1_TBL JOIN JOIN2_TBL ON (JOIN1_TBL.i = JOIN2_TBL.i); ERROR: JOIN expressions are not yet implemented -QUERY: SELECT '' AS "xxx", * - FROM JOIN_TBL CROSS JOIN JOIN2_TBL; -xxx|i|j|x |i| k ----+-+-+-----+-+-- - |1|3|one |1|-1 - |2|2|two |1|-1 - |3|1|three|1|-1 - |4|0|four |1|-1 - |1|3|one |2| 2 - |2|2|two |2| 2 - |3|1|three|2| 2 - |4|0|four |2| 2 - |1|3|one |3|-3 - |2|2|two |3|-3 - |3|1|three|3|-3 - |4|0|four |3|-3 - |1|3|one |2| 4 - |2|2|two |2| 4 - |3|1|three|2| 4 - |4|0|four |2| 4 +SELECT '' AS "xxx", * + FROM JOIN1_TBL JOIN JOIN2_TBL ON (JOIN1_TBL.i = JOIN2_TBL.k); +ERROR: JOIN expressions are not yet implemented +SELECT '' AS "xxx", * + FROM JOIN1_TBL CROSS JOIN JOIN2_TBL; + xxx | i | j | t | i | k +-----+---+---+-------+---+---- + | 1 | 3 | one | 1 | -1 + | 2 | 2 | two | 1 | -1 + | 3 | 1 | three | 1 | -1 + | 4 | 0 | four | 1 | -1 + | 1 | 3 | one | 2 | 2 + | 2 | 2 | two | 2 | 2 + | 3 | 1 | three | 2 | 2 + | 4 | 0 | four | 2 | 2 + | 1 | 3 | one | 3 | -3 + | 2 | 2 | two | 3 | -3 + | 3 | 1 | three | 3 | -3 + | 4 | 0 | four | 3 | -3 + | 1 | 3 | one | 2 | 4 + | 2 | 2 | two | 2 | 4 + | 3 | 1 | three | 2 | 4 + | 4 | 0 | four | 2 | 4 (16 rows) -QUERY: SELECT '' AS "xxx", * - FROM JOIN_TBL JOIN JOIN2_TBL ON (JOIN_TBL.i <= JOIN2_TBL.k); +-- +-- Non-equi-joins +-- +SELECT '' AS "xxx", * + FROM JOIN1_TBL JOIN JOIN2_TBL ON (JOIN1_TBL.i <= JOIN2_TBL.k); ERROR: JOIN expressions are not yet implemented -QUERY: SELECT '' AS "xxx", * - FROM JOIN_TBL OUTER JOIN JOIN2_TBL USING (i); +-- +-- Outer joins +-- +SELECT '' AS "xxx", * NOTICE: OUTER JOIN not yet implemented + FROM JOIN1_TBL OUTER JOIN JOIN2_TBL USING (i); ERROR: JOIN expressions are not yet implemented -QUERY: SELECT '' AS "xxx", * - FROM JOIN_TBL LEFT OUTER JOIN JOIN2_TBL USING (i); +SELECT '' AS "xxx", * NOTICE: LEFT OUTER JOIN not yet implemented + FROM JOIN1_TBL LEFT OUTER JOIN JOIN2_TBL USING (i); ERROR: JOIN expressions are not yet implemented -QUERY: SELECT '' AS "xxx", * - FROM JOIN_TBL RIGHT OUTER JOIN JOIN2_TBL USING (i); +SELECT '' AS "xxx", * NOTICE: RIGHT OUTER JOIN not yet implemented + FROM JOIN1_TBL RIGHT OUTER JOIN JOIN2_TBL USING (i); ERROR: JOIN expressions are not yet implemented -QUERY: SELECT '' AS "xxx", * - FROM JOIN_TBL FULL OUTER JOIN JOIN2_TBL USING (i); +SELECT '' AS "xxx", * NOTICE: FULL OUTER JOIN not yet implemented + FROM JOIN1_TBL FULL OUTER JOIN JOIN2_TBL USING (i); ERROR: JOIN expressions are not yet implemented -QUERY: DROP TABLE JOIN_TBL; -QUERY: DROP TABLE JOIN2_TBL; +-- +-- More complicated constructs +-- +-- +-- Clean up +-- +DROP TABLE JOIN1_TBL; +DROP TABLE JOIN2_TBL; diff --git a/src/test/regress/expected/limit.out b/src/test/regress/expected/limit.out index a46515d334..e14cd6daf7 100644 --- a/src/test/regress/expected/limit.out +++ b/src/test/regress/expected/limit.out @@ -1,106 +1,110 @@ -QUERY: SELECT ''::text AS two, unique1, unique2, stringu1 - FROM onek WHERE unique1 > 50 +-- +-- LIMIT +-- Check the LIMIT/OFFSET feature of SELECT +-- +SELECT ''::text AS two, unique1, unique2, stringu1 + FROM onek WHERE unique1 > 50 ORDER BY unique1 LIMIT 2; -two|unique1|unique2|stringu1 ----+-------+-------+-------- - | 51| 76|ZBAAAA - | 52| 985|ACAAAA + two | unique1 | unique2 | stringu1 +-----+---------+---------+---------- + | 51 | 76 | ZBAAAA + | 52 | 985 | ACAAAA (2 rows) -QUERY: SELECT ''::text AS five, unique1, unique2, stringu1 - FROM onek WHERE unique1 > 60 +SELECT ''::text AS five, unique1, unique2, stringu1 + FROM onek WHERE unique1 > 60 ORDER BY unique1 LIMIT 5; -five|unique1|unique2|stringu1 -----+-------+-------+-------- - | 61| 560|JCAAAA - | 62| 633|KCAAAA - | 63| 296|LCAAAA - | 64| 479|MCAAAA - | 65| 64|NCAAAA + five | unique1 | unique2 | stringu1 +------+---------+---------+---------- + | 61 | 560 | JCAAAA + | 62 | 633 | KCAAAA + | 63 | 296 | LCAAAA + | 64 | 479 | MCAAAA + | 65 | 64 | NCAAAA (5 rows) -QUERY: SELECT ''::text AS two, unique1, unique2, stringu1 +SELECT ''::text AS two, unique1, unique2, stringu1 FROM onek WHERE unique1 > 60 AND unique1 < 63 ORDER BY unique1 LIMIT 5; -two|unique1|unique2|stringu1 ----+-------+-------+-------- - | 61| 560|JCAAAA - | 62| 633|KCAAAA + two | unique1 | unique2 | stringu1 +-----+---------+---------+---------- + | 61 | 560 | JCAAAA + | 62 | 633 | KCAAAA (2 rows) -QUERY: SELECT ''::text AS three, unique1, unique2, stringu1 - FROM onek WHERE unique1 > 100 +SELECT ''::text AS three, unique1, unique2, stringu1 + FROM onek WHERE unique1 > 100 ORDER BY unique1 LIMIT 3 OFFSET 20; -three|unique1|unique2|stringu1 ------+-------+-------+-------- - | 121| 700|REAAAA - | 122| 519|SEAAAA - | 123| 777|TEAAAA + three | unique1 | unique2 | stringu1 +-------+---------+---------+---------- + | 121 | 700 | REAAAA + | 122 | 519 | SEAAAA + | 123 | 777 | TEAAAA (3 rows) -QUERY: SELECT ''::text AS zero, unique1, unique2, stringu1 - FROM onek WHERE unique1 < 50 +SELECT ''::text AS zero, unique1, unique2, stringu1 + FROM onek WHERE unique1 < 50 ORDER BY unique1 DESC LIMIT 8 OFFSET 99; -zero|unique1|unique2|stringu1 -----+-------+-------+-------- + zero | unique1 | unique2 | stringu1 +------+---------+---------+---------- (0 rows) -QUERY: SELECT ''::text AS eleven, unique1, unique2, stringu1 - FROM onek WHERE unique1 < 50 +SELECT ''::text AS eleven, unique1, unique2, stringu1 + FROM onek WHERE unique1 < 50 ORDER BY unique1 DESC LIMIT 20 OFFSET 39; -eleven|unique1|unique2|stringu1 -------+-------+-------+-------- - | 10| 520|KAAAAA - | 9| 49|JAAAAA - | 8| 653|IAAAAA - | 7| 647|HAAAAA - | 6| 978|GAAAAA - | 5| 541|FAAAAA - | 4| 833|EAAAAA - | 3| 431|DAAAAA - | 2| 326|CAAAAA - | 1| 214|BAAAAA - | 0| 998|AAAAAA + eleven | unique1 | unique2 | stringu1 +--------+---------+---------+---------- + | 10 | 520 | KAAAAA + | 9 | 49 | JAAAAA + | 8 | 653 | IAAAAA + | 7 | 647 | HAAAAA + | 6 | 978 | GAAAAA + | 5 | 541 | FAAAAA + | 4 | 833 | EAAAAA + | 3 | 431 | DAAAAA + | 2 | 326 | CAAAAA + | 1 | 214 | BAAAAA + | 0 | 998 | AAAAAA (11 rows) -QUERY: SELECT ''::text AS ten, unique1, unique2, stringu1 +SELECT ''::text AS ten, unique1, unique2, stringu1 FROM onek ORDER BY unique1 OFFSET 990; -ten|unique1|unique2|stringu1 ----+-------+-------+-------- - | 990| 369|CMAAAA - | 991| 426|DMAAAA - | 992| 363|EMAAAA - | 993| 661|FMAAAA - | 994| 695|GMAAAA - | 995| 144|HMAAAA - | 996| 258|IMAAAA - | 997| 21|JMAAAA - | 998| 549|KMAAAA - | 999| 152|LMAAAA + ten | unique1 | unique2 | stringu1 +-----+---------+---------+---------- + | 990 | 369 | CMAAAA + | 991 | 426 | DMAAAA + | 992 | 363 | EMAAAA + | 993 | 661 | FMAAAA + | 994 | 695 | GMAAAA + | 995 | 144 | HMAAAA + | 996 | 258 | IMAAAA + | 997 | 21 | JMAAAA + | 998 | 549 | KMAAAA + | 999 | 152 | LMAAAA (10 rows) -QUERY: SELECT ''::text AS five, unique1, unique2, stringu1 +SELECT ''::text AS five, unique1, unique2, stringu1 FROM onek ORDER BY unique1 OFFSET 990 LIMIT 5; -five|unique1|unique2|stringu1 -----+-------+-------+-------- - | 990| 369|CMAAAA - | 991| 426|DMAAAA - | 992| 363|EMAAAA - | 993| 661|FMAAAA - | 994| 695|GMAAAA + five | unique1 | unique2 | stringu1 +------+---------+---------+---------- + | 990 | 369 | CMAAAA + | 991 | 426 | DMAAAA + | 992 | 363 | EMAAAA + | 993 | 661 | FMAAAA + | 994 | 695 | GMAAAA (5 rows) -QUERY: SELECT ''::text AS five, unique1, unique2, stringu1 +SELECT ''::text AS five, unique1, unique2, stringu1 FROM onek ORDER BY unique1 LIMIT 5, 900; -five|unique1|unique2|stringu1 -----+-------+-------+-------- - | 900| 913|QIAAAA - | 901| 931|RIAAAA - | 902| 702|SIAAAA - | 903| 641|TIAAAA - | 904| 793|UIAAAA + five | unique1 | unique2 | stringu1 +------+---------+---------+---------- + | 900 | 913 | QIAAAA + | 901 | 931 | RIAAAA + | 902 | 702 | SIAAAA + | 903 | 641 | TIAAAA + | 904 | 793 | UIAAAA (5 rows) diff --git a/src/test/regress/expected/plpgsql.out b/src/test/regress/expected/plpgsql.out index dc38722273..73750b9616 100644 --- a/src/test/regress/expected/plpgsql.out +++ b/src/test/regress/expected/plpgsql.out @@ -1,67 +1,82 @@ -QUERY: create table Room ( +-- +-- PLPGSQL +-- +create table Room ( roomno char(8), comment text ); -QUERY: create unique index Room_rno on Room using btree (roomno bpchar_ops); -QUERY: create table WSlot ( +create unique index Room_rno on Room using btree (roomno bpchar_ops); +create table WSlot ( slotname char(20), roomno char(8), slotlink char(20), backlink char(20) ); -QUERY: create unique index WSlot_name on WSlot using btree (slotname bpchar_ops); -QUERY: create table PField ( +create unique index WSlot_name on WSlot using btree (slotname bpchar_ops); +create table PField ( name text, comment text ); -QUERY: create unique index PField_name on PField using btree (name text_ops); -QUERY: create table PSlot ( +create unique index PField_name on PField using btree (name text_ops); +create table PSlot ( slotname char(20), pfname text, slotlink char(20), backlink char(20) ); -QUERY: create unique index PSlot_name on PSlot using btree (slotname bpchar_ops); -QUERY: create table PLine ( +create unique index PSlot_name on PSlot using btree (slotname bpchar_ops); +create table PLine ( slotname char(20), phonenumber char(20), comment text, backlink char(20) ); -QUERY: create unique index PLine_name on PLine using btree (slotname bpchar_ops); -QUERY: create table Hub ( +create unique index PLine_name on PLine using btree (slotname bpchar_ops); +create table Hub ( name char(14), comment text, nslots integer ); -QUERY: create unique index Hub_name on Hub using btree (name bpchar_ops); -QUERY: create table HSlot ( +create unique index Hub_name on Hub using btree (name bpchar_ops); +create table HSlot ( slotname char(20), hubname char(14), slotno integer, slotlink char(20) ); -QUERY: create unique index HSlot_name on HSlot using btree (slotname bpchar_ops); -QUERY: create index HSlot_hubname on HSlot using btree (hubname bpchar_ops); -QUERY: create table System ( +create unique index HSlot_name on HSlot using btree (slotname bpchar_ops); +create index HSlot_hubname on HSlot using btree (hubname bpchar_ops); +create table System ( name text, comment text ); -QUERY: create unique index System_name on System using btree (name text_ops); -QUERY: create table IFace ( +create unique index System_name on System using btree (name text_ops); +create table IFace ( slotname char(20), sysname text, ifname text, slotlink char(20) ); -QUERY: create unique index IFace_name on IFace using btree (slotname bpchar_ops); -QUERY: create table PHone ( +create unique index IFace_name on IFace using btree (slotname bpchar_ops); +create table PHone ( slotname char(20), comment text, slotlink char(20) ); -QUERY: create unique index PHone_name on PHone using btree (slotname bpchar_ops); -QUERY: create function tg_room_au() returns opaque as ' +create unique index PHone_name on PHone using btree (slotname bpchar_ops); +-- ************************************************************ +-- * +-- * Trigger procedures and functions for the patchfield +-- * test of PL/pgSQL +-- * +-- * $Header: /cvsroot/pgsql/src/test/regress/expected/plpgsql.out,v 1.3 2000/01/09 03:48:37 tgl Exp $ +-- * +-- ************************************************************ +-- ************************************************************ +-- * AFTER UPDATE on Room +-- * - If room no changes let wall slots follow +-- ************************************************************ +create function tg_room_au() returns opaque as ' begin if new.roomno != old.roomno then update WSlot set roomno = new.roomno where roomno = old.roomno; @@ -69,17 +84,25 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_room_au after update +create trigger tg_room_au after update on Room for each row execute procedure tg_room_au(); -QUERY: create function tg_room_ad() returns opaque as ' +-- ************************************************************ +-- * AFTER DELETE on Room +-- * - delete wall slots in this room +-- ************************************************************ +create function tg_room_ad() returns opaque as ' begin delete from WSlot where roomno = old.roomno; return old; end; ' language 'plpgsql'; -QUERY: create trigger tg_room_ad after delete +create trigger tg_room_ad after delete on Room for each row execute procedure tg_room_ad(); -QUERY: create function tg_wslot_biu() returns opaque as ' +-- ************************************************************ +-- * BEFORE INSERT or UPDATE on WSlot +-- * - Check that room exists +-- ************************************************************ +create function tg_wslot_biu() returns opaque as ' begin if count(*) = 0 from Room where roomno = new.roomno then raise exception ''Room % does not exist'', new.roomno; @@ -87,9 +110,13 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_wslot_biu before insert or update +create trigger tg_wslot_biu before insert or update on WSlot for each row execute procedure tg_wslot_biu(); -QUERY: create function tg_pfield_au() returns opaque as ' +-- ************************************************************ +-- * AFTER UPDATE on PField +-- * - Let PSlots of this field follow +-- ************************************************************ +create function tg_pfield_au() returns opaque as ' begin if new.name != old.name then update PSlot set pfname = new.name where pfname = old.name; @@ -97,17 +124,25 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_pfield_au after update +create trigger tg_pfield_au after update on PField for each row execute procedure tg_pfield_au(); -QUERY: create function tg_pfield_ad() returns opaque as ' +-- ************************************************************ +-- * AFTER DELETE on PField +-- * - Remove all slots of this patchfield +-- ************************************************************ +create function tg_pfield_ad() returns opaque as ' begin delete from PSlot where pfname = old.name; return old; end; ' language 'plpgsql'; -QUERY: create trigger tg_pfield_ad after delete +create trigger tg_pfield_ad after delete on PField for each row execute procedure tg_pfield_ad(); -QUERY: create function tg_pslot_biu() returns opaque as ' +-- ************************************************************ +-- * BEFORE INSERT or UPDATE on PSlot +-- * - Ensure that our patchfield does exist +-- ************************************************************ +create function tg_pslot_biu() returns opaque as ' declare pfrec record; rename new to ps; @@ -119,9 +154,13 @@ begin return ps; end; ' language 'plpgsql'; -QUERY: create trigger tg_pslot_biu before insert or update +create trigger tg_pslot_biu before insert or update on PSlot for each row execute procedure tg_pslot_biu(); -QUERY: create function tg_system_au() returns opaque as ' +-- ************************************************************ +-- * AFTER UPDATE on System +-- * - If system name changes let interfaces follow +-- ************************************************************ +create function tg_system_au() returns opaque as ' begin if new.name != old.name then update IFace set sysname = new.name where sysname = old.name; @@ -129,9 +168,13 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_system_au after update +create trigger tg_system_au after update on System for each row execute procedure tg_system_au(); -QUERY: create function tg_iface_biu() returns opaque as ' +-- ************************************************************ +-- * BEFORE INSERT or UPDATE on IFace +-- * - set the slotname to IF.sysname.ifname +-- ************************************************************ +create function tg_iface_biu() returns opaque as ' declare sname text; sysrec record; @@ -150,9 +193,13 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_iface_biu before insert or update +create trigger tg_iface_biu before insert or update on IFace for each row execute procedure tg_iface_biu(); -QUERY: create function tg_hub_a() returns opaque as ' +-- ************************************************************ +-- * AFTER INSERT or UPDATE or DELETE on Hub +-- * - insert/delete/rename slots as required +-- ************************************************************ +create function tg_hub_a() returns opaque as ' declare hname text; dummy integer; @@ -174,9 +221,12 @@ begin end if; end; ' language 'plpgsql'; -QUERY: create trigger tg_hub_a after insert or update or delete +create trigger tg_hub_a after insert or update or delete on Hub for each row execute procedure tg_hub_a(); -QUERY: create function tg_hub_adjustslots(bpchar, integer, integer) +-- ************************************************************ +-- * Support function to add/remove slots of Hub +-- ************************************************************ +create function tg_hub_adjustslots(bpchar, integer, integer) returns integer as ' declare hname alias for $1; @@ -197,7 +247,12 @@ begin return 0; end; ' language 'plpgsql'; -QUERY: create function tg_hslot_biu() returns opaque as ' +-- ************************************************************ +-- * BEFORE INSERT or UPDATE on HSlot +-- * - prevent from manual manipulation +-- * - set the slotname to HS.hubname.slotno +-- ************************************************************ +create function tg_hslot_biu() returns opaque as ' declare sname text; xname HSlot.slotname%TYPE; @@ -227,9 +282,13 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_hslot_biu before insert or update +create trigger tg_hslot_biu before insert or update on HSlot for each row execute procedure tg_hslot_biu(); -QUERY: create function tg_hslot_bd() returns opaque as ' +-- ************************************************************ +-- * BEFORE DELETE on HSlot +-- * - prevent from manual manipulation +-- ************************************************************ +create function tg_hslot_bd() returns opaque as ' declare hubrec record; begin @@ -243,9 +302,13 @@ begin raise exception ''no manual manipulation of HSlot''; end; ' language 'plpgsql'; -QUERY: create trigger tg_hslot_bd before delete +create trigger tg_hslot_bd before delete on HSlot for each row execute procedure tg_hslot_bd(); -QUERY: create function tg_chkslotname() returns opaque as ' +-- ************************************************************ +-- * BEFORE INSERT on all slots +-- * - Check name prefix +-- ************************************************************ +create function tg_chkslotname() returns opaque as ' begin if substr(new.slotname, 1, 2) != tg_argv[0] then raise exception ''slotname must begin with %'', tg_argv[0]; @@ -253,17 +316,21 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_chkslotname before insert +create trigger tg_chkslotname before insert on PSlot for each row execute procedure tg_chkslotname('PS'); -QUERY: create trigger tg_chkslotname before insert +create trigger tg_chkslotname before insert on WSlot for each row execute procedure tg_chkslotname('WS'); -QUERY: create trigger tg_chkslotname before insert +create trigger tg_chkslotname before insert on PLine for each row execute procedure tg_chkslotname('PL'); -QUERY: create trigger tg_chkslotname before insert +create trigger tg_chkslotname before insert on IFace for each row execute procedure tg_chkslotname('IF'); -QUERY: create trigger tg_chkslotname before insert +create trigger tg_chkslotname before insert on PHone for each row execute procedure tg_chkslotname('PH'); -QUERY: create function tg_chkslotlink() returns opaque as ' +-- ************************************************************ +-- * BEFORE INSERT or UPDATE on all slots with slotlink +-- * - Set slotlink to empty string if NULL value given +-- ************************************************************ +create function tg_chkslotlink() returns opaque as ' begin if new.slotlink isnull then new.slotlink := ''''; @@ -271,17 +338,21 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_chkslotlink before insert or update +create trigger tg_chkslotlink before insert or update on PSlot for each row execute procedure tg_chkslotlink(); -QUERY: create trigger tg_chkslotlink before insert or update +create trigger tg_chkslotlink before insert or update on WSlot for each row execute procedure tg_chkslotlink(); -QUERY: create trigger tg_chkslotlink before insert or update +create trigger tg_chkslotlink before insert or update on IFace for each row execute procedure tg_chkslotlink(); -QUERY: create trigger tg_chkslotlink before insert or update +create trigger tg_chkslotlink before insert or update on HSlot for each row execute procedure tg_chkslotlink(); -QUERY: create trigger tg_chkslotlink before insert or update +create trigger tg_chkslotlink before insert or update on PHone for each row execute procedure tg_chkslotlink(); -QUERY: create function tg_chkbacklink() returns opaque as ' +-- ************************************************************ +-- * BEFORE INSERT or UPDATE on all slots with backlink +-- * - Set backlink to empty string if NULL value given +-- ************************************************************ +create function tg_chkbacklink() returns opaque as ' begin if new.backlink isnull then new.backlink := ''''; @@ -289,13 +360,17 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_chkbacklink before insert or update +create trigger tg_chkbacklink before insert or update on PSlot for each row execute procedure tg_chkbacklink(); -QUERY: create trigger tg_chkbacklink before insert or update +create trigger tg_chkbacklink before insert or update on WSlot for each row execute procedure tg_chkbacklink(); -QUERY: create trigger tg_chkbacklink before insert or update +create trigger tg_chkbacklink before insert or update on PLine for each row execute procedure tg_chkbacklink(); -QUERY: create function tg_pslot_bu() returns opaque as ' +-- ************************************************************ +-- * BEFORE UPDATE on PSlot +-- * - do delete/insert instead of update if name changes +-- ************************************************************ +create function tg_pslot_bu() returns opaque as ' begin if new.slotname != old.slotname then delete from PSlot where slotname = old.slotname; @@ -315,9 +390,13 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_pslot_bu before update +create trigger tg_pslot_bu before update on PSlot for each row execute procedure tg_pslot_bu(); -QUERY: create function tg_wslot_bu() returns opaque as ' +-- ************************************************************ +-- * BEFORE UPDATE on WSlot +-- * - do delete/insert instead of update if name changes +-- ************************************************************ +create function tg_wslot_bu() returns opaque as ' begin if new.slotname != old.slotname then delete from WSlot where slotname = old.slotname; @@ -337,9 +416,13 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_wslot_bu before update +create trigger tg_wslot_bu before update on WSlot for each row execute procedure tg_Wslot_bu(); -QUERY: create function tg_pline_bu() returns opaque as ' +-- ************************************************************ +-- * BEFORE UPDATE on PLine +-- * - do delete/insert instead of update if name changes +-- ************************************************************ +create function tg_pline_bu() returns opaque as ' begin if new.slotname != old.slotname then delete from PLine where slotname = old.slotname; @@ -359,9 +442,13 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_pline_bu before update +create trigger tg_pline_bu before update on PLine for each row execute procedure tg_pline_bu(); -QUERY: create function tg_iface_bu() returns opaque as ' +-- ************************************************************ +-- * BEFORE UPDATE on IFace +-- * - do delete/insert instead of update if name changes +-- ************************************************************ +create function tg_iface_bu() returns opaque as ' begin if new.slotname != old.slotname then delete from IFace where slotname = old.slotname; @@ -381,9 +468,13 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_iface_bu before update +create trigger tg_iface_bu before update on IFace for each row execute procedure tg_iface_bu(); -QUERY: create function tg_hslot_bu() returns opaque as ' +-- ************************************************************ +-- * BEFORE UPDATE on HSlot +-- * - do delete/insert instead of update if name changes +-- ************************************************************ +create function tg_hslot_bu() returns opaque as ' begin if new.slotname != old.slotname or new.hubname != old.hubname then delete from HSlot where slotname = old.slotname; @@ -403,9 +494,13 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_hslot_bu before update +create trigger tg_hslot_bu before update on HSlot for each row execute procedure tg_hslot_bu(); -QUERY: create function tg_phone_bu() returns opaque as ' +-- ************************************************************ +-- * BEFORE UPDATE on PHone +-- * - do delete/insert instead of update if name changes +-- ************************************************************ +create function tg_phone_bu() returns opaque as ' begin if new.slotname != old.slotname then delete from PHone where slotname = old.slotname; @@ -423,9 +518,13 @@ begin return new; end; ' language 'plpgsql'; -QUERY: create trigger tg_phone_bu before update +create trigger tg_phone_bu before update on PHone for each row execute procedure tg_phone_bu(); -QUERY: create function tg_backlink_a() returns opaque as ' +-- ************************************************************ +-- * AFTER INSERT or UPDATE or DELETE on slot with backlink +-- * - Ensure that the opponent correctly points back to us +-- ************************************************************ +create function tg_backlink_a() returns opaque as ' declare dummy integer; begin @@ -458,13 +557,17 @@ begin end if; end; ' language 'plpgsql'; -QUERY: create trigger tg_backlink_a after insert or update or delete +create trigger tg_backlink_a after insert or update or delete on PSlot for each row execute procedure tg_backlink_a('PS'); -QUERY: create trigger tg_backlink_a after insert or update or delete +create trigger tg_backlink_a after insert or update or delete on WSlot for each row execute procedure tg_backlink_a('WS'); -QUERY: create trigger tg_backlink_a after insert or update or delete +create trigger tg_backlink_a after insert or update or delete on PLine for each row execute procedure tg_backlink_a('PL'); -QUERY: create function tg_backlink_set(bpchar, bpchar) +-- ************************************************************ +-- * Support function to set the opponents backlink field +-- * if it does not already point to the requested slot +-- ************************************************************ +create function tg_backlink_set(bpchar, bpchar) returns integer as ' declare myname alias for $1; @@ -476,11 +579,11 @@ begin mytype := substr(myname, 1, 2); link := mytype || substr(blname, 1, 2); if link = ''PLPL'' then - raise exception + raise exception ''backlink between two phone lines does not make sense''; end if; if link in (''PLWS'', ''WSPL'') then - raise exception + raise exception ''direct link of phone line to wall slot not permitted''; end if; if mytype = ''PS'' then @@ -516,7 +619,11 @@ begin raise exception ''illegal backlink beginning with %'', mytype; end; ' language 'plpgsql'; -QUERY: create function tg_backlink_unset(bpchar, bpchar) +-- ************************************************************ +-- * Support function to clear out the backlink field if +-- * it still points to specific slot +-- ************************************************************ +create function tg_backlink_unset(bpchar, bpchar) returns integer as ' declare myname alias for $1; @@ -557,7 +664,11 @@ begin end if; end; ' language 'plpgsql'; -QUERY: create function tg_slotlink_a() returns opaque as ' +-- ************************************************************ +-- * AFTER INSERT or UPDATE or DELETE on slot with slotlink +-- * - Ensure that the opponent correctly points back to us +-- ************************************************************ +create function tg_slotlink_a() returns opaque as ' declare dummy integer; begin @@ -590,17 +701,21 @@ begin end if; end; ' language 'plpgsql'; -QUERY: create trigger tg_slotlink_a after insert or update or delete +create trigger tg_slotlink_a after insert or update or delete on PSlot for each row execute procedure tg_slotlink_a('PS'); -QUERY: create trigger tg_slotlink_a after insert or update or delete +create trigger tg_slotlink_a after insert or update or delete on WSlot for each row execute procedure tg_slotlink_a('WS'); -QUERY: create trigger tg_slotlink_a after insert or update or delete +create trigger tg_slotlink_a after insert or update or delete on IFace for each row execute procedure tg_slotlink_a('IF'); -QUERY: create trigger tg_slotlink_a after insert or update or delete +create trigger tg_slotlink_a after insert or update or delete on HSlot for each row execute procedure tg_slotlink_a('HS'); -QUERY: create trigger tg_slotlink_a after insert or update or delete +create trigger tg_slotlink_a after insert or update or delete on PHone for each row execute procedure tg_slotlink_a('PH'); -QUERY: create function tg_slotlink_set(bpchar, bpchar) +-- ************************************************************ +-- * Support function to set the opponents slotlink field +-- * if it does not already point to the requested slot +-- ************************************************************ +create function tg_slotlink_set(bpchar, bpchar) returns integer as ' declare myname alias for $1; @@ -612,19 +727,19 @@ begin mytype := substr(myname, 1, 2); link := mytype || substr(blname, 1, 2); if link = ''PHPH'' then - raise exception + raise exception ''slotlink between two phones does not make sense''; end if; if link in (''PHHS'', ''HSPH'') then - raise exception + raise exception ''link of phone to hub does not make sense''; end if; if link in (''PHIF'', ''IFPH'') then - raise exception + raise exception ''link of phone to hub does not make sense''; end if; if link in (''PSWS'', ''WSPS'') then - raise exception + raise exception ''slotlink from patchslot to wallslot not permitted''; end if; if mytype = ''PS'' then @@ -680,7 +795,11 @@ begin raise exception ''illegal slotlink beginning with %'', mytype; end; ' language 'plpgsql'; -QUERY: create function tg_slotlink_unset(bpchar, bpchar) +-- ************************************************************ +-- * Support function to clear out the slotlink field if +-- * it still points to specific slot +-- ************************************************************ +create function tg_slotlink_unset(bpchar, bpchar) returns integer as ' declare myname alias for $1; @@ -741,7 +860,10 @@ begin end if; end; ' language 'plpgsql'; -QUERY: create function pslot_backlink_view(bpchar) +-- ************************************************************ +-- * Describe the backside of a patchfield slot +-- ************************************************************ +create function pslot_backlink_view(bpchar) returns text as ' <> declare @@ -781,7 +903,10 @@ begin return rec.backlink; end; ' language 'plpgsql'; -QUERY: create function pslot_slotlink_view(bpchar) +-- ************************************************************ +-- * Describe the front of a patchfield slot +-- ************************************************************ +create function pslot_slotlink_view(bpchar) returns text as ' declare psrec record; @@ -812,7 +937,10 @@ begin return psrec.slotlink; end; ' language 'plpgsql'; -QUERY: create function wslot_slotlink_view(bpchar) +-- ************************************************************ +-- * Describe the front of a wall connector slot +-- ************************************************************ +create function wslot_slotlink_view(bpchar) returns text as ' declare rec record; @@ -857,480 +985,535 @@ begin return rec.slotlink; end; ' language 'plpgsql'; -QUERY: create view Pfield_v1 as select PF.pfname, PF.slotname, +-- ************************************************************ +-- * View of a patchfield describing backside and patches +-- ************************************************************ +create view Pfield_v1 as select PF.pfname, PF.slotname, pslot_backlink_view(PF.slotname) as backside, pslot_slotlink_view(PF.slotname) as patch from PSlot PF; -QUERY: insert into Room values ('001', 'Entrance'); -QUERY: insert into Room values ('002', 'Office'); -QUERY: insert into Room values ('003', 'Office'); -QUERY: insert into Room values ('004', 'Technical'); -QUERY: insert into Room values ('101', 'Office'); -QUERY: insert into Room values ('102', 'Conference'); -QUERY: insert into Room values ('103', 'Restroom'); -QUERY: insert into Room values ('104', 'Technical'); -QUERY: insert into Room values ('105', 'Office'); -QUERY: insert into Room values ('106', 'Office'); -QUERY: insert into WSlot values ('WS.001.1a', '001', '', ''); -QUERY: insert into WSlot values ('WS.001.1b', '001', '', ''); -QUERY: insert into WSlot values ('WS.001.2a', '001', '', ''); -QUERY: insert into WSlot values ('WS.001.2b', '001', '', ''); -QUERY: insert into WSlot values ('WS.001.3a', '001', '', ''); -QUERY: insert into WSlot values ('WS.001.3b', '001', '', ''); -QUERY: insert into WSlot values ('WS.002.1a', '002', '', ''); -QUERY: insert into WSlot values ('WS.002.1b', '002', '', ''); -QUERY: insert into WSlot values ('WS.002.2a', '002', '', ''); -QUERY: insert into WSlot values ('WS.002.2b', '002', '', ''); -QUERY: insert into WSlot values ('WS.002.3a', '002', '', ''); -QUERY: insert into WSlot values ('WS.002.3b', '002', '', ''); -QUERY: insert into WSlot values ('WS.003.1a', '003', '', ''); -QUERY: insert into WSlot values ('WS.003.1b', '003', '', ''); -QUERY: insert into WSlot values ('WS.003.2a', '003', '', ''); -QUERY: insert into WSlot values ('WS.003.2b', '003', '', ''); -QUERY: insert into WSlot values ('WS.003.3a', '003', '', ''); -QUERY: insert into WSlot values ('WS.003.3b', '003', '', ''); -QUERY: insert into WSlot values ('WS.101.1a', '101', '', ''); -QUERY: insert into WSlot values ('WS.101.1b', '101', '', ''); -QUERY: insert into WSlot values ('WS.101.2a', '101', '', ''); -QUERY: insert into WSlot values ('WS.101.2b', '101', '', ''); -QUERY: insert into WSlot values ('WS.101.3a', '101', '', ''); -QUERY: insert into WSlot values ('WS.101.3b', '101', '', ''); -QUERY: insert into WSlot values ('WS.102.1a', '102', '', ''); -QUERY: insert into WSlot values ('WS.102.1b', '102', '', ''); -QUERY: insert into WSlot values ('WS.102.2a', '102', '', ''); -QUERY: insert into WSlot values ('WS.102.2b', '102', '', ''); -QUERY: insert into WSlot values ('WS.102.3a', '102', '', ''); -QUERY: insert into WSlot values ('WS.102.3b', '102', '', ''); -QUERY: insert into WSlot values ('WS.105.1a', '105', '', ''); -QUERY: insert into WSlot values ('WS.105.1b', '105', '', ''); -QUERY: insert into WSlot values ('WS.105.2a', '105', '', ''); -QUERY: insert into WSlot values ('WS.105.2b', '105', '', ''); -QUERY: insert into WSlot values ('WS.105.3a', '105', '', ''); -QUERY: insert into WSlot values ('WS.105.3b', '105', '', ''); -QUERY: insert into WSlot values ('WS.106.1a', '106', '', ''); -QUERY: insert into WSlot values ('WS.106.1b', '106', '', ''); -QUERY: insert into WSlot values ('WS.106.2a', '106', '', ''); -QUERY: insert into WSlot values ('WS.106.2b', '106', '', ''); -QUERY: insert into WSlot values ('WS.106.3a', '106', '', ''); -QUERY: insert into WSlot values ('WS.106.3b', '106', '', ''); -QUERY: insert into PField values ('PF0_1', 'Wallslots basement'); -QUERY: insert into PSlot values ('PS.base.a1', 'PF0_1', '', ''); -QUERY: insert into PSlot values ('PS.base.a2', 'PF0_1', '', ''); -QUERY: insert into PSlot values ('PS.base.a3', 'PF0_1', '', ''); -QUERY: insert into PSlot values ('PS.base.a4', 'PF0_1', '', ''); -QUERY: insert into PSlot values ('PS.base.a5', 'PF0_1', '', ''); -QUERY: insert into PSlot values ('PS.base.a6', 'PF0_1', '', ''); -QUERY: insert into PSlot values ('PS.base.b1', 'PF0_1', '', 'WS.002.1a'); -QUERY: insert into PSlot values ('PS.base.b2', 'PF0_1', '', 'WS.002.1b'); -QUERY: insert into PSlot values ('PS.base.b3', 'PF0_1', '', 'WS.002.2a'); -QUERY: insert into PSlot values ('PS.base.b4', 'PF0_1', '', 'WS.002.2b'); -QUERY: insert into PSlot values ('PS.base.b5', 'PF0_1', '', 'WS.002.3a'); -QUERY: insert into PSlot values ('PS.base.b6', 'PF0_1', '', 'WS.002.3b'); -QUERY: insert into PSlot values ('PS.base.c1', 'PF0_1', '', 'WS.003.1a'); -QUERY: insert into PSlot values ('PS.base.c2', 'PF0_1', '', 'WS.003.1b'); -QUERY: insert into PSlot values ('PS.base.c3', 'PF0_1', '', 'WS.003.2a'); -QUERY: insert into PSlot values ('PS.base.c4', 'PF0_1', '', 'WS.003.2b'); -QUERY: insert into PSlot values ('PS.base.c5', 'PF0_1', '', 'WS.003.3a'); -QUERY: insert into PSlot values ('PS.base.c6', 'PF0_1', '', 'WS.003.3b'); -QUERY: insert into PField values ('PF0_X', 'Phonelines basement'); -QUERY: insert into PSlot values ('PS.base.ta1', 'PF0_X', '', ''); -QUERY: insert into PSlot values ('PS.base.ta2', 'PF0_X', '', ''); -QUERY: insert into PSlot values ('PS.base.ta3', 'PF0_X', '', ''); -QUERY: insert into PSlot values ('PS.base.ta4', 'PF0_X', '', ''); -QUERY: insert into PSlot values ('PS.base.ta5', 'PF0_X', '', ''); -QUERY: insert into PSlot values ('PS.base.ta6', 'PF0_X', '', ''); -QUERY: insert into PSlot values ('PS.base.tb1', 'PF0_X', '', ''); -QUERY: insert into PSlot values ('PS.base.tb2', 'PF0_X', '', ''); -QUERY: insert into PSlot values ('PS.base.tb3', 'PF0_X', '', ''); -QUERY: insert into PSlot values ('PS.base.tb4', 'PF0_X', '', ''); -QUERY: insert into PSlot values ('PS.base.tb5', 'PF0_X', '', ''); -QUERY: insert into PSlot values ('PS.base.tb6', 'PF0_X', '', ''); -QUERY: insert into PField values ('PF1_1', 'Wallslots 1st floor'); -QUERY: insert into PSlot values ('PS.1st.a1', 'PF1_1', '', 'WS.101.1a'); -QUERY: insert into PSlot values ('PS.1st.a2', 'PF1_1', '', 'WS.101.1b'); -QUERY: insert into PSlot values ('PS.1st.a3', 'PF1_1', '', 'WS.101.2a'); -QUERY: insert into PSlot values ('PS.1st.a4', 'PF1_1', '', 'WS.101.2b'); -QUERY: insert into PSlot values ('PS.1st.a5', 'PF1_1', '', 'WS.101.3a'); -QUERY: insert into PSlot values ('PS.1st.a6', 'PF1_1', '', 'WS.101.3b'); -QUERY: insert into PSlot values ('PS.1st.b1', 'PF1_1', '', 'WS.102.1a'); -QUERY: insert into PSlot values ('PS.1st.b2', 'PF1_1', '', 'WS.102.1b'); -QUERY: insert into PSlot values ('PS.1st.b3', 'PF1_1', '', 'WS.102.2a'); -QUERY: insert into PSlot values ('PS.1st.b4', 'PF1_1', '', 'WS.102.2b'); -QUERY: insert into PSlot values ('PS.1st.b5', 'PF1_1', '', 'WS.102.3a'); -QUERY: insert into PSlot values ('PS.1st.b6', 'PF1_1', '', 'WS.102.3b'); -QUERY: insert into PSlot values ('PS.1st.c1', 'PF1_1', '', 'WS.105.1a'); -QUERY: insert into PSlot values ('PS.1st.c2', 'PF1_1', '', 'WS.105.1b'); -QUERY: insert into PSlot values ('PS.1st.c3', 'PF1_1', '', 'WS.105.2a'); -QUERY: insert into PSlot values ('PS.1st.c4', 'PF1_1', '', 'WS.105.2b'); -QUERY: insert into PSlot values ('PS.1st.c5', 'PF1_1', '', 'WS.105.3a'); -QUERY: insert into PSlot values ('PS.1st.c6', 'PF1_1', '', 'WS.105.3b'); -QUERY: insert into PSlot values ('PS.1st.d1', 'PF1_1', '', 'WS.106.1a'); -QUERY: insert into PSlot values ('PS.1st.d2', 'PF1_1', '', 'WS.106.1b'); -QUERY: insert into PSlot values ('PS.1st.d3', 'PF1_1', '', 'WS.106.2a'); -QUERY: insert into PSlot values ('PS.1st.d4', 'PF1_1', '', 'WS.106.2b'); -QUERY: insert into PSlot values ('PS.1st.d5', 'PF1_1', '', 'WS.106.3a'); -QUERY: insert into PSlot values ('PS.1st.d6', 'PF1_1', '', 'WS.106.3b'); -QUERY: update PSlot set backlink = 'WS.001.1a' where slotname = 'PS.base.a1'; -QUERY: update PSlot set backlink = 'WS.001.1b' where slotname = 'PS.base.a3'; -QUERY: select * from WSlot where roomno = '001' order by slotname; -slotname |roomno |slotlink |backlink ---------------------+--------+--------------------+-------------------- -WS.001.1a |001 | |PS.base.a1 -WS.001.1b |001 | |PS.base.a3 -WS.001.2a |001 | | -WS.001.2b |001 | | -WS.001.3a |001 | | -WS.001.3b |001 | | +-- +-- First we build the house - so we create the rooms +-- +insert into Room values ('001', 'Entrance'); +insert into Room values ('002', 'Office'); +insert into Room values ('003', 'Office'); +insert into Room values ('004', 'Technical'); +insert into Room values ('101', 'Office'); +insert into Room values ('102', 'Conference'); +insert into Room values ('103', 'Restroom'); +insert into Room values ('104', 'Technical'); +insert into Room values ('105', 'Office'); +insert into Room values ('106', 'Office'); +-- +-- Second we install the wall connectors +-- +insert into WSlot values ('WS.001.1a', '001', '', ''); +insert into WSlot values ('WS.001.1b', '001', '', ''); +insert into WSlot values ('WS.001.2a', '001', '', ''); +insert into WSlot values ('WS.001.2b', '001', '', ''); +insert into WSlot values ('WS.001.3a', '001', '', ''); +insert into WSlot values ('WS.001.3b', '001', '', ''); +insert into WSlot values ('WS.002.1a', '002', '', ''); +insert into WSlot values ('WS.002.1b', '002', '', ''); +insert into WSlot values ('WS.002.2a', '002', '', ''); +insert into WSlot values ('WS.002.2b', '002', '', ''); +insert into WSlot values ('WS.002.3a', '002', '', ''); +insert into WSlot values ('WS.002.3b', '002', '', ''); +insert into WSlot values ('WS.003.1a', '003', '', ''); +insert into WSlot values ('WS.003.1b', '003', '', ''); +insert into WSlot values ('WS.003.2a', '003', '', ''); +insert into WSlot values ('WS.003.2b', '003', '', ''); +insert into WSlot values ('WS.003.3a', '003', '', ''); +insert into WSlot values ('WS.003.3b', '003', '', ''); +insert into WSlot values ('WS.101.1a', '101', '', ''); +insert into WSlot values ('WS.101.1b', '101', '', ''); +insert into WSlot values ('WS.101.2a', '101', '', ''); +insert into WSlot values ('WS.101.2b', '101', '', ''); +insert into WSlot values ('WS.101.3a', '101', '', ''); +insert into WSlot values ('WS.101.3b', '101', '', ''); +insert into WSlot values ('WS.102.1a', '102', '', ''); +insert into WSlot values ('WS.102.1b', '102', '', ''); +insert into WSlot values ('WS.102.2a', '102', '', ''); +insert into WSlot values ('WS.102.2b', '102', '', ''); +insert into WSlot values ('WS.102.3a', '102', '', ''); +insert into WSlot values ('WS.102.3b', '102', '', ''); +insert into WSlot values ('WS.105.1a', '105', '', ''); +insert into WSlot values ('WS.105.1b', '105', '', ''); +insert into WSlot values ('WS.105.2a', '105', '', ''); +insert into WSlot values ('WS.105.2b', '105', '', ''); +insert into WSlot values ('WS.105.3a', '105', '', ''); +insert into WSlot values ('WS.105.3b', '105', '', ''); +insert into WSlot values ('WS.106.1a', '106', '', ''); +insert into WSlot values ('WS.106.1b', '106', '', ''); +insert into WSlot values ('WS.106.2a', '106', '', ''); +insert into WSlot values ('WS.106.2b', '106', '', ''); +insert into WSlot values ('WS.106.3a', '106', '', ''); +insert into WSlot values ('WS.106.3b', '106', '', ''); +-- +-- Now create the patch fields and their slots +-- +insert into PField values ('PF0_1', 'Wallslots basement'); +-- +-- The cables for these will be made later, so they are unconnected for now +-- +insert into PSlot values ('PS.base.a1', 'PF0_1', '', ''); +insert into PSlot values ('PS.base.a2', 'PF0_1', '', ''); +insert into PSlot values ('PS.base.a3', 'PF0_1', '', ''); +insert into PSlot values ('PS.base.a4', 'PF0_1', '', ''); +insert into PSlot values ('PS.base.a5', 'PF0_1', '', ''); +insert into PSlot values ('PS.base.a6', 'PF0_1', '', ''); +-- +-- These are already wired to the wall connectors +-- +insert into PSlot values ('PS.base.b1', 'PF0_1', '', 'WS.002.1a'); +insert into PSlot values ('PS.base.b2', 'PF0_1', '', 'WS.002.1b'); +insert into PSlot values ('PS.base.b3', 'PF0_1', '', 'WS.002.2a'); +insert into PSlot values ('PS.base.b4', 'PF0_1', '', 'WS.002.2b'); +insert into PSlot values ('PS.base.b5', 'PF0_1', '', 'WS.002.3a'); +insert into PSlot values ('PS.base.b6', 'PF0_1', '', 'WS.002.3b'); +insert into PSlot values ('PS.base.c1', 'PF0_1', '', 'WS.003.1a'); +insert into PSlot values ('PS.base.c2', 'PF0_1', '', 'WS.003.1b'); +insert into PSlot values ('PS.base.c3', 'PF0_1', '', 'WS.003.2a'); +insert into PSlot values ('PS.base.c4', 'PF0_1', '', 'WS.003.2b'); +insert into PSlot values ('PS.base.c5', 'PF0_1', '', 'WS.003.3a'); +insert into PSlot values ('PS.base.c6', 'PF0_1', '', 'WS.003.3b'); +-- +-- This patchfield will be renamed later into PF0_2 - so its +-- slots references in pfname should follow +-- +insert into PField values ('PF0_X', 'Phonelines basement'); +insert into PSlot values ('PS.base.ta1', 'PF0_X', '', ''); +insert into PSlot values ('PS.base.ta2', 'PF0_X', '', ''); +insert into PSlot values ('PS.base.ta3', 'PF0_X', '', ''); +insert into PSlot values ('PS.base.ta4', 'PF0_X', '', ''); +insert into PSlot values ('PS.base.ta5', 'PF0_X', '', ''); +insert into PSlot values ('PS.base.ta6', 'PF0_X', '', ''); +insert into PSlot values ('PS.base.tb1', 'PF0_X', '', ''); +insert into PSlot values ('PS.base.tb2', 'PF0_X', '', ''); +insert into PSlot values ('PS.base.tb3', 'PF0_X', '', ''); +insert into PSlot values ('PS.base.tb4', 'PF0_X', '', ''); +insert into PSlot values ('PS.base.tb5', 'PF0_X', '', ''); +insert into PSlot values ('PS.base.tb6', 'PF0_X', '', ''); +insert into PField values ('PF1_1', 'Wallslots 1st floor'); +insert into PSlot values ('PS.1st.a1', 'PF1_1', '', 'WS.101.1a'); +insert into PSlot values ('PS.1st.a2', 'PF1_1', '', 'WS.101.1b'); +insert into PSlot values ('PS.1st.a3', 'PF1_1', '', 'WS.101.2a'); +insert into PSlot values ('PS.1st.a4', 'PF1_1', '', 'WS.101.2b'); +insert into PSlot values ('PS.1st.a5', 'PF1_1', '', 'WS.101.3a'); +insert into PSlot values ('PS.1st.a6', 'PF1_1', '', 'WS.101.3b'); +insert into PSlot values ('PS.1st.b1', 'PF1_1', '', 'WS.102.1a'); +insert into PSlot values ('PS.1st.b2', 'PF1_1', '', 'WS.102.1b'); +insert into PSlot values ('PS.1st.b3', 'PF1_1', '', 'WS.102.2a'); +insert into PSlot values ('PS.1st.b4', 'PF1_1', '', 'WS.102.2b'); +insert into PSlot values ('PS.1st.b5', 'PF1_1', '', 'WS.102.3a'); +insert into PSlot values ('PS.1st.b6', 'PF1_1', '', 'WS.102.3b'); +insert into PSlot values ('PS.1st.c1', 'PF1_1', '', 'WS.105.1a'); +insert into PSlot values ('PS.1st.c2', 'PF1_1', '', 'WS.105.1b'); +insert into PSlot values ('PS.1st.c3', 'PF1_1', '', 'WS.105.2a'); +insert into PSlot values ('PS.1st.c4', 'PF1_1', '', 'WS.105.2b'); +insert into PSlot values ('PS.1st.c5', 'PF1_1', '', 'WS.105.3a'); +insert into PSlot values ('PS.1st.c6', 'PF1_1', '', 'WS.105.3b'); +insert into PSlot values ('PS.1st.d1', 'PF1_1', '', 'WS.106.1a'); +insert into PSlot values ('PS.1st.d2', 'PF1_1', '', 'WS.106.1b'); +insert into PSlot values ('PS.1st.d3', 'PF1_1', '', 'WS.106.2a'); +insert into PSlot values ('PS.1st.d4', 'PF1_1', '', 'WS.106.2b'); +insert into PSlot values ('PS.1st.d5', 'PF1_1', '', 'WS.106.3a'); +insert into PSlot values ('PS.1st.d6', 'PF1_1', '', 'WS.106.3b'); +-- +-- Now we wire the wall connectors 1a-2a in room 001 to the +-- patchfield. In the second update we make an error, and +-- correct it after +-- +update PSlot set backlink = 'WS.001.1a' where slotname = 'PS.base.a1'; +update PSlot set backlink = 'WS.001.1b' where slotname = 'PS.base.a3'; +select * from WSlot where roomno = '001' order by slotname; + slotname | roomno | slotlink | backlink +----------------------+----------+----------------------+---------------------- + WS.001.1a | 001 | | PS.base.a1 + WS.001.1b | 001 | | PS.base.a3 + WS.001.2a | 001 | | + WS.001.2b | 001 | | + WS.001.3a | 001 | | + WS.001.3b | 001 | | (6 rows) -QUERY: select * from PSlot where slotname ~ 'PS.base.a' order by slotname; -slotname |pfname|slotlink |backlink ---------------------+------+--------------------+-------------------- -PS.base.a1 |PF0_1 | |WS.001.1a -PS.base.a2 |PF0_1 | | -PS.base.a3 |PF0_1 | |WS.001.1b -PS.base.a4 |PF0_1 | | -PS.base.a5 |PF0_1 | | -PS.base.a6 |PF0_1 | | +select * from PSlot where slotname ~ 'PS.base.a' order by slotname; + slotname | pfname | slotlink | backlink +----------------------+--------+----------------------+---------------------- + PS.base.a1 | PF0_1 | | WS.001.1a + PS.base.a2 | PF0_1 | | + PS.base.a3 | PF0_1 | | WS.001.1b + PS.base.a4 | PF0_1 | | + PS.base.a5 | PF0_1 | | + PS.base.a6 | PF0_1 | | (6 rows) -QUERY: update PSlot set backlink = 'WS.001.2a' where slotname = 'PS.base.a3'; -QUERY: select * from WSlot where roomno = '001' order by slotname; -slotname |roomno |slotlink |backlink ---------------------+--------+--------------------+-------------------- -WS.001.1a |001 | |PS.base.a1 -WS.001.1b |001 | | -WS.001.2a |001 | |PS.base.a3 -WS.001.2b |001 | | -WS.001.3a |001 | | -WS.001.3b |001 | | +update PSlot set backlink = 'WS.001.2a' where slotname = 'PS.base.a3'; +select * from WSlot where roomno = '001' order by slotname; + slotname | roomno | slotlink | backlink +----------------------+----------+----------------------+---------------------- + WS.001.1a | 001 | | PS.base.a1 + WS.001.1b | 001 | | + WS.001.2a | 001 | | PS.base.a3 + WS.001.2b | 001 | | + WS.001.3a | 001 | | + WS.001.3b | 001 | | (6 rows) -QUERY: select * from PSlot where slotname ~ 'PS.base.a' order by slotname; -slotname |pfname|slotlink |backlink ---------------------+------+--------------------+-------------------- -PS.base.a1 |PF0_1 | |WS.001.1a -PS.base.a2 |PF0_1 | | -PS.base.a3 |PF0_1 | |WS.001.2a -PS.base.a4 |PF0_1 | | -PS.base.a5 |PF0_1 | | -PS.base.a6 |PF0_1 | | +select * from PSlot where slotname ~ 'PS.base.a' order by slotname; + slotname | pfname | slotlink | backlink +----------------------+--------+----------------------+---------------------- + PS.base.a1 | PF0_1 | | WS.001.1a + PS.base.a2 | PF0_1 | | + PS.base.a3 | PF0_1 | | WS.001.2a + PS.base.a4 | PF0_1 | | + PS.base.a5 | PF0_1 | | + PS.base.a6 | PF0_1 | | (6 rows) -QUERY: update PSlot set backlink = 'WS.001.1b' where slotname = 'PS.base.a2'; -QUERY: select * from WSlot where roomno = '001' order by slotname; -slotname |roomno |slotlink |backlink ---------------------+--------+--------------------+-------------------- -WS.001.1a |001 | |PS.base.a1 -WS.001.1b |001 | |PS.base.a2 -WS.001.2a |001 | |PS.base.a3 -WS.001.2b |001 | | -WS.001.3a |001 | | -WS.001.3b |001 | | +update PSlot set backlink = 'WS.001.1b' where slotname = 'PS.base.a2'; +select * from WSlot where roomno = '001' order by slotname; + slotname | roomno | slotlink | backlink +----------------------+----------+----------------------+---------------------- + WS.001.1a | 001 | | PS.base.a1 + WS.001.1b | 001 | | PS.base.a2 + WS.001.2a | 001 | | PS.base.a3 + WS.001.2b | 001 | | + WS.001.3a | 001 | | + WS.001.3b | 001 | | (6 rows) -QUERY: select * from PSlot where slotname ~ 'PS.base.a' order by slotname; -slotname |pfname|slotlink |backlink ---------------------+------+--------------------+-------------------- -PS.base.a1 |PF0_1 | |WS.001.1a -PS.base.a2 |PF0_1 | |WS.001.1b -PS.base.a3 |PF0_1 | |WS.001.2a -PS.base.a4 |PF0_1 | | -PS.base.a5 |PF0_1 | | -PS.base.a6 |PF0_1 | | +select * from PSlot where slotname ~ 'PS.base.a' order by slotname; + slotname | pfname | slotlink | backlink +----------------------+--------+----------------------+---------------------- + PS.base.a1 | PF0_1 | | WS.001.1a + PS.base.a2 | PF0_1 | | WS.001.1b + PS.base.a3 | PF0_1 | | WS.001.2a + PS.base.a4 | PF0_1 | | + PS.base.a5 | PF0_1 | | + PS.base.a6 | PF0_1 | | (6 rows) -QUERY: update WSlot set backlink = 'PS.base.a4' where slotname = 'WS.001.2b'; -QUERY: update WSlot set backlink = 'PS.base.a6' where slotname = 'WS.001.3a'; -QUERY: select * from WSlot where roomno = '001' order by slotname; -slotname |roomno |slotlink |backlink ---------------------+--------+--------------------+-------------------- -WS.001.1a |001 | |PS.base.a1 -WS.001.1b |001 | |PS.base.a2 -WS.001.2a |001 | |PS.base.a3 -WS.001.2b |001 | |PS.base.a4 -WS.001.3a |001 | |PS.base.a6 -WS.001.3b |001 | | +-- +-- Same procedure for 2b-3b but this time updating the WSlot instead +-- of the PSlot. Due to the triggers the result is the same: +-- WSlot and corresponding PSlot point to each other. +-- +update WSlot set backlink = 'PS.base.a4' where slotname = 'WS.001.2b'; +update WSlot set backlink = 'PS.base.a6' where slotname = 'WS.001.3a'; +select * from WSlot where roomno = '001' order by slotname; + slotname | roomno | slotlink | backlink +----------------------+----------+----------------------+---------------------- + WS.001.1a | 001 | | PS.base.a1 + WS.001.1b | 001 | | PS.base.a2 + WS.001.2a | 001 | | PS.base.a3 + WS.001.2b | 001 | | PS.base.a4 + WS.001.3a | 001 | | PS.base.a6 + WS.001.3b | 001 | | (6 rows) -QUERY: select * from PSlot where slotname ~ 'PS.base.a' order by slotname; -slotname |pfname|slotlink |backlink ---------------------+------+--------------------+-------------------- -PS.base.a1 |PF0_1 | |WS.001.1a -PS.base.a2 |PF0_1 | |WS.001.1b -PS.base.a3 |PF0_1 | |WS.001.2a -PS.base.a4 |PF0_1 | |WS.001.2b -PS.base.a5 |PF0_1 | | -PS.base.a6 |PF0_1 | |WS.001.3a +select * from PSlot where slotname ~ 'PS.base.a' order by slotname; + slotname | pfname | slotlink | backlink +----------------------+--------+----------------------+---------------------- + PS.base.a1 | PF0_1 | | WS.001.1a + PS.base.a2 | PF0_1 | | WS.001.1b + PS.base.a3 | PF0_1 | | WS.001.2a + PS.base.a4 | PF0_1 | | WS.001.2b + PS.base.a5 | PF0_1 | | + PS.base.a6 | PF0_1 | | WS.001.3a (6 rows) -QUERY: update WSlot set backlink = 'PS.base.a6' where slotname = 'WS.001.3b'; -QUERY: select * from WSlot where roomno = '001' order by slotname; -slotname |roomno |slotlink |backlink ---------------------+--------+--------------------+-------------------- -WS.001.1a |001 | |PS.base.a1 -WS.001.1b |001 | |PS.base.a2 -WS.001.2a |001 | |PS.base.a3 -WS.001.2b |001 | |PS.base.a4 -WS.001.3a |001 | | -WS.001.3b |001 | |PS.base.a6 +update WSlot set backlink = 'PS.base.a6' where slotname = 'WS.001.3b'; +select * from WSlot where roomno = '001' order by slotname; + slotname | roomno | slotlink | backlink +----------------------+----------+----------------------+---------------------- + WS.001.1a | 001 | | PS.base.a1 + WS.001.1b | 001 | | PS.base.a2 + WS.001.2a | 001 | | PS.base.a3 + WS.001.2b | 001 | | PS.base.a4 + WS.001.3a | 001 | | + WS.001.3b | 001 | | PS.base.a6 (6 rows) -QUERY: select * from PSlot where slotname ~ 'PS.base.a' order by slotname; -slotname |pfname|slotlink |backlink ---------------------+------+--------------------+-------------------- -PS.base.a1 |PF0_1 | |WS.001.1a -PS.base.a2 |PF0_1 | |WS.001.1b -PS.base.a3 |PF0_1 | |WS.001.2a -PS.base.a4 |PF0_1 | |WS.001.2b -PS.base.a5 |PF0_1 | | -PS.base.a6 |PF0_1 | |WS.001.3b +select * from PSlot where slotname ~ 'PS.base.a' order by slotname; + slotname | pfname | slotlink | backlink +----------------------+--------+----------------------+---------------------- + PS.base.a1 | PF0_1 | | WS.001.1a + PS.base.a2 | PF0_1 | | WS.001.1b + PS.base.a3 | PF0_1 | | WS.001.2a + PS.base.a4 | PF0_1 | | WS.001.2b + PS.base.a5 | PF0_1 | | + PS.base.a6 | PF0_1 | | WS.001.3b (6 rows) -QUERY: update WSlot set backlink = 'PS.base.a5' where slotname = 'WS.001.3a'; -QUERY: select * from WSlot where roomno = '001' order by slotname; -slotname |roomno |slotlink |backlink ---------------------+--------+--------------------+-------------------- -WS.001.1a |001 | |PS.base.a1 -WS.001.1b |001 | |PS.base.a2 -WS.001.2a |001 | |PS.base.a3 -WS.001.2b |001 | |PS.base.a4 -WS.001.3a |001 | |PS.base.a5 -WS.001.3b |001 | |PS.base.a6 +update WSlot set backlink = 'PS.base.a5' where slotname = 'WS.001.3a'; +select * from WSlot where roomno = '001' order by slotname; + slotname | roomno | slotlink | backlink +----------------------+----------+----------------------+---------------------- + WS.001.1a | 001 | | PS.base.a1 + WS.001.1b | 001 | | PS.base.a2 + WS.001.2a | 001 | | PS.base.a3 + WS.001.2b | 001 | | PS.base.a4 + WS.001.3a | 001 | | PS.base.a5 + WS.001.3b | 001 | | PS.base.a6 (6 rows) -QUERY: select * from PSlot where slotname ~ 'PS.base.a' order by slotname; -slotname |pfname|slotlink |backlink ---------------------+------+--------------------+-------------------- -PS.base.a1 |PF0_1 | |WS.001.1a -PS.base.a2 |PF0_1 | |WS.001.1b -PS.base.a3 |PF0_1 | |WS.001.2a -PS.base.a4 |PF0_1 | |WS.001.2b -PS.base.a5 |PF0_1 | |WS.001.3a -PS.base.a6 |PF0_1 | |WS.001.3b +select * from PSlot where slotname ~ 'PS.base.a' order by slotname; + slotname | pfname | slotlink | backlink +----------------------+--------+----------------------+---------------------- + PS.base.a1 | PF0_1 | | WS.001.1a + PS.base.a2 | PF0_1 | | WS.001.1b + PS.base.a3 | PF0_1 | | WS.001.2a + PS.base.a4 | PF0_1 | | WS.001.2b + PS.base.a5 | PF0_1 | | WS.001.3a + PS.base.a6 | PF0_1 | | WS.001.3b (6 rows) -QUERY: insert into PField values ('PF1_2', 'Phonelines 1st floor'); -QUERY: insert into PSlot values ('PS.1st.ta1', 'PF1_2', '', ''); -QUERY: insert into PSlot values ('PS.1st.ta2', 'PF1_2', '', ''); -QUERY: insert into PSlot values ('PS.1st.ta3', 'PF1_2', '', ''); -QUERY: insert into PSlot values ('PS.1st.ta4', 'PF1_2', '', ''); -QUERY: insert into PSlot values ('PS.1st.ta5', 'PF1_2', '', ''); -QUERY: insert into PSlot values ('PS.1st.ta6', 'PF1_2', '', ''); -QUERY: insert into PSlot values ('PS.1st.tb1', 'PF1_2', '', ''); -QUERY: insert into PSlot values ('PS.1st.tb2', 'PF1_2', '', ''); -QUERY: insert into PSlot values ('PS.1st.tb3', 'PF1_2', '', ''); -QUERY: insert into PSlot values ('PS.1st.tb4', 'PF1_2', '', ''); -QUERY: insert into PSlot values ('PS.1st.tb5', 'PF1_2', '', ''); -QUERY: insert into PSlot values ('PS.1st.tb6', 'PF1_2', '', ''); -QUERY: update PField set name = 'PF0_2' where name = 'PF0_X'; -QUERY: select * from PSlot order by slotname; -slotname |pfname|slotlink |backlink ---------------------+------+--------------------+-------------------- -PS.1st.a1 |PF1_1 | |WS.101.1a -PS.1st.a2 |PF1_1 | |WS.101.1b -PS.1st.a3 |PF1_1 | |WS.101.2a -PS.1st.a4 |PF1_1 | |WS.101.2b -PS.1st.a5 |PF1_1 | |WS.101.3a -PS.1st.a6 |PF1_1 | |WS.101.3b -PS.1st.b1 |PF1_1 | |WS.102.1a -PS.1st.b2 |PF1_1 | |WS.102.1b -PS.1st.b3 |PF1_1 | |WS.102.2a -PS.1st.b4 |PF1_1 | |WS.102.2b -PS.1st.b5 |PF1_1 | |WS.102.3a -PS.1st.b6 |PF1_1 | |WS.102.3b -PS.1st.c1 |PF1_1 | |WS.105.1a -PS.1st.c2 |PF1_1 | |WS.105.1b -PS.1st.c3 |PF1_1 | |WS.105.2a -PS.1st.c4 |PF1_1 | |WS.105.2b -PS.1st.c5 |PF1_1 | |WS.105.3a -PS.1st.c6 |PF1_1 | |WS.105.3b -PS.1st.d1 |PF1_1 | |WS.106.1a -PS.1st.d2 |PF1_1 | |WS.106.1b -PS.1st.d3 |PF1_1 | |WS.106.2a -PS.1st.d4 |PF1_1 | |WS.106.2b -PS.1st.d5 |PF1_1 | |WS.106.3a -PS.1st.d6 |PF1_1 | |WS.106.3b -PS.1st.ta1 |PF1_2 | | -PS.1st.ta2 |PF1_2 | | -PS.1st.ta3 |PF1_2 | | -PS.1st.ta4 |PF1_2 | | -PS.1st.ta5 |PF1_2 | | -PS.1st.ta6 |PF1_2 | | -PS.1st.tb1 |PF1_2 | | -PS.1st.tb2 |PF1_2 | | -PS.1st.tb3 |PF1_2 | | -PS.1st.tb4 |PF1_2 | | -PS.1st.tb5 |PF1_2 | | -PS.1st.tb6 |PF1_2 | | -PS.base.a1 |PF0_1 | |WS.001.1a -PS.base.a2 |PF0_1 | |WS.001.1b -PS.base.a3 |PF0_1 | |WS.001.2a -PS.base.a4 |PF0_1 | |WS.001.2b -PS.base.a5 |PF0_1 | |WS.001.3a -PS.base.a6 |PF0_1 | |WS.001.3b -PS.base.b1 |PF0_1 | |WS.002.1a -PS.base.b2 |PF0_1 | |WS.002.1b -PS.base.b3 |PF0_1 | |WS.002.2a -PS.base.b4 |PF0_1 | |WS.002.2b -PS.base.b5 |PF0_1 | |WS.002.3a -PS.base.b6 |PF0_1 | |WS.002.3b -PS.base.c1 |PF0_1 | |WS.003.1a -PS.base.c2 |PF0_1 | |WS.003.1b -PS.base.c3 |PF0_1 | |WS.003.2a -PS.base.c4 |PF0_1 | |WS.003.2b -PS.base.c5 |PF0_1 | |WS.003.3a -PS.base.c6 |PF0_1 | |WS.003.3b -PS.base.ta1 |PF0_2 | | -PS.base.ta2 |PF0_2 | | -PS.base.ta3 |PF0_2 | | -PS.base.ta4 |PF0_2 | | -PS.base.ta5 |PF0_2 | | -PS.base.ta6 |PF0_2 | | -PS.base.tb1 |PF0_2 | | -PS.base.tb2 |PF0_2 | | -PS.base.tb3 |PF0_2 | | -PS.base.tb4 |PF0_2 | | -PS.base.tb5 |PF0_2 | | -PS.base.tb6 |PF0_2 | | +insert into PField values ('PF1_2', 'Phonelines 1st floor'); +insert into PSlot values ('PS.1st.ta1', 'PF1_2', '', ''); +insert into PSlot values ('PS.1st.ta2', 'PF1_2', '', ''); +insert into PSlot values ('PS.1st.ta3', 'PF1_2', '', ''); +insert into PSlot values ('PS.1st.ta4', 'PF1_2', '', ''); +insert into PSlot values ('PS.1st.ta5', 'PF1_2', '', ''); +insert into PSlot values ('PS.1st.ta6', 'PF1_2', '', ''); +insert into PSlot values ('PS.1st.tb1', 'PF1_2', '', ''); +insert into PSlot values ('PS.1st.tb2', 'PF1_2', '', ''); +insert into PSlot values ('PS.1st.tb3', 'PF1_2', '', ''); +insert into PSlot values ('PS.1st.tb4', 'PF1_2', '', ''); +insert into PSlot values ('PS.1st.tb5', 'PF1_2', '', ''); +insert into PSlot values ('PS.1st.tb6', 'PF1_2', '', ''); +-- +-- Fix the wrong name for patchfield PF0_2 +-- +update PField set name = 'PF0_2' where name = 'PF0_X'; +select * from PSlot order by slotname; + slotname | pfname | slotlink | backlink +----------------------+--------+----------------------+---------------------- + PS.1st.a1 | PF1_1 | | WS.101.1a + PS.1st.a2 | PF1_1 | | WS.101.1b + PS.1st.a3 | PF1_1 | | WS.101.2a + PS.1st.a4 | PF1_1 | | WS.101.2b + PS.1st.a5 | PF1_1 | | WS.101.3a + PS.1st.a6 | PF1_1 | | WS.101.3b + PS.1st.b1 | PF1_1 | | WS.102.1a + PS.1st.b2 | PF1_1 | | WS.102.1b + PS.1st.b3 | PF1_1 | | WS.102.2a + PS.1st.b4 | PF1_1 | | WS.102.2b + PS.1st.b5 | PF1_1 | | WS.102.3a + PS.1st.b6 | PF1_1 | | WS.102.3b + PS.1st.c1 | PF1_1 | | WS.105.1a + PS.1st.c2 | PF1_1 | | WS.105.1b + PS.1st.c3 | PF1_1 | | WS.105.2a + PS.1st.c4 | PF1_1 | | WS.105.2b + PS.1st.c5 | PF1_1 | | WS.105.3a + PS.1st.c6 | PF1_1 | | WS.105.3b + PS.1st.d1 | PF1_1 | | WS.106.1a + PS.1st.d2 | PF1_1 | | WS.106.1b + PS.1st.d3 | PF1_1 | | WS.106.2a + PS.1st.d4 | PF1_1 | | WS.106.2b + PS.1st.d5 | PF1_1 | | WS.106.3a + PS.1st.d6 | PF1_1 | | WS.106.3b + PS.1st.ta1 | PF1_2 | | + PS.1st.ta2 | PF1_2 | | + PS.1st.ta3 | PF1_2 | | + PS.1st.ta4 | PF1_2 | | + PS.1st.ta5 | PF1_2 | | + PS.1st.ta6 | PF1_2 | | + PS.1st.tb1 | PF1_2 | | + PS.1st.tb2 | PF1_2 | | + PS.1st.tb3 | PF1_2 | | + PS.1st.tb4 | PF1_2 | | + PS.1st.tb5 | PF1_2 | | + PS.1st.tb6 | PF1_2 | | + PS.base.a1 | PF0_1 | | WS.001.1a + PS.base.a2 | PF0_1 | | WS.001.1b + PS.base.a3 | PF0_1 | | WS.001.2a + PS.base.a4 | PF0_1 | | WS.001.2b + PS.base.a5 | PF0_1 | | WS.001.3a + PS.base.a6 | PF0_1 | | WS.001.3b + PS.base.b1 | PF0_1 | | WS.002.1a + PS.base.b2 | PF0_1 | | WS.002.1b + PS.base.b3 | PF0_1 | | WS.002.2a + PS.base.b4 | PF0_1 | | WS.002.2b + PS.base.b5 | PF0_1 | | WS.002.3a + PS.base.b6 | PF0_1 | | WS.002.3b + PS.base.c1 | PF0_1 | | WS.003.1a + PS.base.c2 | PF0_1 | | WS.003.1b + PS.base.c3 | PF0_1 | | WS.003.2a + PS.base.c4 | PF0_1 | | WS.003.2b + PS.base.c5 | PF0_1 | | WS.003.3a + PS.base.c6 | PF0_1 | | WS.003.3b + PS.base.ta1 | PF0_2 | | + PS.base.ta2 | PF0_2 | | + PS.base.ta3 | PF0_2 | | + PS.base.ta4 | PF0_2 | | + PS.base.ta5 | PF0_2 | | + PS.base.ta6 | PF0_2 | | + PS.base.tb1 | PF0_2 | | + PS.base.tb2 | PF0_2 | | + PS.base.tb3 | PF0_2 | | + PS.base.tb4 | PF0_2 | | + PS.base.tb5 | PF0_2 | | + PS.base.tb6 | PF0_2 | | (66 rows) -QUERY: select * from WSlot order by slotname; -slotname |roomno |slotlink |backlink ---------------------+--------+--------------------+-------------------- -WS.001.1a |001 | |PS.base.a1 -WS.001.1b |001 | |PS.base.a2 -WS.001.2a |001 | |PS.base.a3 -WS.001.2b |001 | |PS.base.a4 -WS.001.3a |001 | |PS.base.a5 -WS.001.3b |001 | |PS.base.a6 -WS.002.1a |002 | |PS.base.b1 -WS.002.1b |002 | |PS.base.b2 -WS.002.2a |002 | |PS.base.b3 -WS.002.2b |002 | |PS.base.b4 -WS.002.3a |002 | |PS.base.b5 -WS.002.3b |002 | |PS.base.b6 -WS.003.1a |003 | |PS.base.c1 -WS.003.1b |003 | |PS.base.c2 -WS.003.2a |003 | |PS.base.c3 -WS.003.2b |003 | |PS.base.c4 -WS.003.3a |003 | |PS.base.c5 -WS.003.3b |003 | |PS.base.c6 -WS.101.1a |101 | |PS.1st.a1 -WS.101.1b |101 | |PS.1st.a2 -WS.101.2a |101 | |PS.1st.a3 -WS.101.2b |101 | |PS.1st.a4 -WS.101.3a |101 | |PS.1st.a5 -WS.101.3b |101 | |PS.1st.a6 -WS.102.1a |102 | |PS.1st.b1 -WS.102.1b |102 | |PS.1st.b2 -WS.102.2a |102 | |PS.1st.b3 -WS.102.2b |102 | |PS.1st.b4 -WS.102.3a |102 | |PS.1st.b5 -WS.102.3b |102 | |PS.1st.b6 -WS.105.1a |105 | |PS.1st.c1 -WS.105.1b |105 | |PS.1st.c2 -WS.105.2a |105 | |PS.1st.c3 -WS.105.2b |105 | |PS.1st.c4 -WS.105.3a |105 | |PS.1st.c5 -WS.105.3b |105 | |PS.1st.c6 -WS.106.1a |106 | |PS.1st.d1 -WS.106.1b |106 | |PS.1st.d2 -WS.106.2a |106 | |PS.1st.d3 -WS.106.2b |106 | |PS.1st.d4 -WS.106.3a |106 | |PS.1st.d5 -WS.106.3b |106 | |PS.1st.d6 +select * from WSlot order by slotname; + slotname | roomno | slotlink | backlink +----------------------+----------+----------------------+---------------------- + WS.001.1a | 001 | | PS.base.a1 + WS.001.1b | 001 | | PS.base.a2 + WS.001.2a | 001 | | PS.base.a3 + WS.001.2b | 001 | | PS.base.a4 + WS.001.3a | 001 | | PS.base.a5 + WS.001.3b | 001 | | PS.base.a6 + WS.002.1a | 002 | | PS.base.b1 + WS.002.1b | 002 | | PS.base.b2 + WS.002.2a | 002 | | PS.base.b3 + WS.002.2b | 002 | | PS.base.b4 + WS.002.3a | 002 | | PS.base.b5 + WS.002.3b | 002 | | PS.base.b6 + WS.003.1a | 003 | | PS.base.c1 + WS.003.1b | 003 | | PS.base.c2 + WS.003.2a | 003 | | PS.base.c3 + WS.003.2b | 003 | | PS.base.c4 + WS.003.3a | 003 | | PS.base.c5 + WS.003.3b | 003 | | PS.base.c6 + WS.101.1a | 101 | | PS.1st.a1 + WS.101.1b | 101 | | PS.1st.a2 + WS.101.2a | 101 | | PS.1st.a3 + WS.101.2b | 101 | | PS.1st.a4 + WS.101.3a | 101 | | PS.1st.a5 + WS.101.3b | 101 | | PS.1st.a6 + WS.102.1a | 102 | | PS.1st.b1 + WS.102.1b | 102 | | PS.1st.b2 + WS.102.2a | 102 | | PS.1st.b3 + WS.102.2b | 102 | | PS.1st.b4 + WS.102.3a | 102 | | PS.1st.b5 + WS.102.3b | 102 | | PS.1st.b6 + WS.105.1a | 105 | | PS.1st.c1 + WS.105.1b | 105 | | PS.1st.c2 + WS.105.2a | 105 | | PS.1st.c3 + WS.105.2b | 105 | | PS.1st.c4 + WS.105.3a | 105 | | PS.1st.c5 + WS.105.3b | 105 | | PS.1st.c6 + WS.106.1a | 106 | | PS.1st.d1 + WS.106.1b | 106 | | PS.1st.d2 + WS.106.2a | 106 | | PS.1st.d3 + WS.106.2b | 106 | | PS.1st.d4 + WS.106.3a | 106 | | PS.1st.d5 + WS.106.3b | 106 | | PS.1st.d6 (42 rows) -QUERY: insert into PLine values ('PL.001', '-0', 'Central call', 'PS.base.ta1'); -QUERY: insert into PLine values ('PL.002', '-101', '', 'PS.base.ta2'); -QUERY: insert into PLine values ('PL.003', '-102', '', 'PS.base.ta3'); -QUERY: insert into PLine values ('PL.004', '-103', '', 'PS.base.ta5'); -QUERY: insert into PLine values ('PL.005', '-104', '', 'PS.base.ta6'); -QUERY: insert into PLine values ('PL.006', '-106', '', 'PS.base.tb2'); -QUERY: insert into PLine values ('PL.007', '-108', '', 'PS.base.tb3'); -QUERY: insert into PLine values ('PL.008', '-109', '', 'PS.base.tb4'); -QUERY: insert into PLine values ('PL.009', '-121', '', 'PS.base.tb5'); -QUERY: insert into PLine values ('PL.010', '-122', '', 'PS.base.tb6'); -QUERY: insert into PLine values ('PL.015', '-134', '', 'PS.1st.ta1'); -QUERY: insert into PLine values ('PL.016', '-137', '', 'PS.1st.ta3'); -QUERY: insert into PLine values ('PL.017', '-139', '', 'PS.1st.ta4'); -QUERY: insert into PLine values ('PL.018', '-362', '', 'PS.1st.tb1'); -QUERY: insert into PLine values ('PL.019', '-363', '', 'PS.1st.tb2'); -QUERY: insert into PLine values ('PL.020', '-364', '', 'PS.1st.tb3'); -QUERY: insert into PLine values ('PL.021', '-365', '', 'PS.1st.tb5'); -QUERY: insert into PLine values ('PL.022', '-367', '', 'PS.1st.tb6'); -QUERY: insert into PLine values ('PL.028', '-501', 'Fax entrance', 'PS.base.ta2'); -QUERY: insert into PLine values ('PL.029', '-502', 'Fax 1st floor', 'PS.1st.ta1'); -QUERY: insert into PHone values ('PH.hc001', 'Hicom standard', 'WS.001.1a'); -QUERY: update PSlot set slotlink = 'PS.base.ta1' where slotname = 'PS.base.a1'; -QUERY: insert into PHone values ('PH.hc002', 'Hicom standard', 'WS.002.1a'); -QUERY: update PSlot set slotlink = 'PS.base.ta5' where slotname = 'PS.base.b1'; -QUERY: insert into PHone values ('PH.hc003', 'Hicom standard', 'WS.002.2a'); -QUERY: update PSlot set slotlink = 'PS.base.tb2' where slotname = 'PS.base.b3'; -QUERY: insert into PHone values ('PH.fax001', 'Canon fax', 'WS.001.2a'); -QUERY: update PSlot set slotlink = 'PS.base.ta2' where slotname = 'PS.base.a3'; -QUERY: insert into Hub values ('base.hub1', 'Patchfield PF0_1 hub', 16); -QUERY: insert into System values ('orion', 'PC'); -QUERY: insert into IFace values ('IF', 'orion', 'eth0', 'WS.002.1b'); -QUERY: update PSlot set slotlink = 'HS.base.hub1.1' where slotname = 'PS.base.b2'; -QUERY: select * from PField_v1 where pfname = 'PF0_1' order by slotname; -pfname|slotname |backside |patch -------+--------------------+--------------------------------------------------------+--------------------------------------------- -PF0_1 |PS.base.a1 |WS.001.1a in room 001 -> Phone PH.hc001 (Hicom standard)|PS.base.ta1 -> Phone line -0 (Central call) -PF0_1 |PS.base.a2 |WS.001.1b in room 001 -> - |- -PF0_1 |PS.base.a3 |WS.001.2a in room 001 -> Phone PH.fax001 (Canon fax) |PS.base.ta2 -> Phone line -501 (Fax entrance) -PF0_1 |PS.base.a4 |WS.001.2b in room 001 -> - |- -PF0_1 |PS.base.a5 |WS.001.3a in room 001 -> - |- -PF0_1 |PS.base.a6 |WS.001.3b in room 001 -> - |- -PF0_1 |PS.base.b1 |WS.002.1a in room 002 -> Phone PH.hc002 (Hicom standard)|PS.base.ta5 -> Phone line -103 -PF0_1 |PS.base.b2 |WS.002.1b in room 002 -> orion IF eth0 (PC) |Patchfield PF0_1 hub slot 1 -PF0_1 |PS.base.b3 |WS.002.2a in room 002 -> Phone PH.hc003 (Hicom standard)|PS.base.tb2 -> Phone line -106 -PF0_1 |PS.base.b4 |WS.002.2b in room 002 -> - |- -PF0_1 |PS.base.b5 |WS.002.3a in room 002 -> - |- -PF0_1 |PS.base.b6 |WS.002.3b in room 002 -> - |- -PF0_1 |PS.base.c1 |WS.003.1a in room 003 -> - |- -PF0_1 |PS.base.c2 |WS.003.1b in room 003 -> - |- -PF0_1 |PS.base.c3 |WS.003.2a in room 003 -> - |- -PF0_1 |PS.base.c4 |WS.003.2b in room 003 -> - |- -PF0_1 |PS.base.c5 |WS.003.3a in room 003 -> - |- -PF0_1 |PS.base.c6 |WS.003.3b in room 003 -> - |- +-- +-- Install the central phone system and create the phone numbers. +-- They are weired on insert to the patchfields. Again the +-- triggers automatically tell the PSlots to update their +-- backlink field. +-- +insert into PLine values ('PL.001', '-0', 'Central call', 'PS.base.ta1'); +insert into PLine values ('PL.002', '-101', '', 'PS.base.ta2'); +insert into PLine values ('PL.003', '-102', '', 'PS.base.ta3'); +insert into PLine values ('PL.004', '-103', '', 'PS.base.ta5'); +insert into PLine values ('PL.005', '-104', '', 'PS.base.ta6'); +insert into PLine values ('PL.006', '-106', '', 'PS.base.tb2'); +insert into PLine values ('PL.007', '-108', '', 'PS.base.tb3'); +insert into PLine values ('PL.008', '-109', '', 'PS.base.tb4'); +insert into PLine values ('PL.009', '-121', '', 'PS.base.tb5'); +insert into PLine values ('PL.010', '-122', '', 'PS.base.tb6'); +insert into PLine values ('PL.015', '-134', '', 'PS.1st.ta1'); +insert into PLine values ('PL.016', '-137', '', 'PS.1st.ta3'); +insert into PLine values ('PL.017', '-139', '', 'PS.1st.ta4'); +insert into PLine values ('PL.018', '-362', '', 'PS.1st.tb1'); +insert into PLine values ('PL.019', '-363', '', 'PS.1st.tb2'); +insert into PLine values ('PL.020', '-364', '', 'PS.1st.tb3'); +insert into PLine values ('PL.021', '-365', '', 'PS.1st.tb5'); +insert into PLine values ('PL.022', '-367', '', 'PS.1st.tb6'); +insert into PLine values ('PL.028', '-501', 'Fax entrance', 'PS.base.ta2'); +insert into PLine values ('PL.029', '-502', 'Fax 1st floor', 'PS.1st.ta1'); +-- +-- Buy some phones, plug them into the wall and patch the +-- phone lines to the corresponding patchfield slots. +-- +insert into PHone values ('PH.hc001', 'Hicom standard', 'WS.001.1a'); +update PSlot set slotlink = 'PS.base.ta1' where slotname = 'PS.base.a1'; +insert into PHone values ('PH.hc002', 'Hicom standard', 'WS.002.1a'); +update PSlot set slotlink = 'PS.base.ta5' where slotname = 'PS.base.b1'; +insert into PHone values ('PH.hc003', 'Hicom standard', 'WS.002.2a'); +update PSlot set slotlink = 'PS.base.tb2' where slotname = 'PS.base.b3'; +insert into PHone values ('PH.fax001', 'Canon fax', 'WS.001.2a'); +update PSlot set slotlink = 'PS.base.ta2' where slotname = 'PS.base.a3'; +-- +-- Install a hub at one of the patchfields, plug a computers +-- ethernet interface into the wall and patch it to the hub. +-- +insert into Hub values ('base.hub1', 'Patchfield PF0_1 hub', 16); +insert into System values ('orion', 'PC'); +insert into IFace values ('IF', 'orion', 'eth0', 'WS.002.1b'); +update PSlot set slotlink = 'HS.base.hub1.1' where slotname = 'PS.base.b2'; +-- +-- Now we take a look at the patchfield +-- +select * from PField_v1 where pfname = 'PF0_1' order by slotname; + pfname | slotname | backside | patch +--------+----------------------+----------------------------------------------------------+----------------------------------------------- + PF0_1 | PS.base.a1 | WS.001.1a in room 001 -> Phone PH.hc001 (Hicom standard) | PS.base.ta1 -> Phone line -0 (Central call) + PF0_1 | PS.base.a2 | WS.001.1b in room 001 -> - | - + PF0_1 | PS.base.a3 | WS.001.2a in room 001 -> Phone PH.fax001 (Canon fax) | PS.base.ta2 -> Phone line -501 (Fax entrance) + PF0_1 | PS.base.a4 | WS.001.2b in room 001 -> - | - + PF0_1 | PS.base.a5 | WS.001.3a in room 001 -> - | - + PF0_1 | PS.base.a6 | WS.001.3b in room 001 -> - | - + PF0_1 | PS.base.b1 | WS.002.1a in room 002 -> Phone PH.hc002 (Hicom standard) | PS.base.ta5 -> Phone line -103 + PF0_1 | PS.base.b2 | WS.002.1b in room 002 -> orion IF eth0 (PC) | Patchfield PF0_1 hub slot 1 + PF0_1 | PS.base.b3 | WS.002.2a in room 002 -> Phone PH.hc003 (Hicom standard) | PS.base.tb2 -> Phone line -106 + PF0_1 | PS.base.b4 | WS.002.2b in room 002 -> - | - + PF0_1 | PS.base.b5 | WS.002.3a in room 002 -> - | - + PF0_1 | PS.base.b6 | WS.002.3b in room 002 -> - | - + PF0_1 | PS.base.c1 | WS.003.1a in room 003 -> - | - + PF0_1 | PS.base.c2 | WS.003.1b in room 003 -> - | - + PF0_1 | PS.base.c3 | WS.003.2a in room 003 -> - | - + PF0_1 | PS.base.c4 | WS.003.2b in room 003 -> - | - + PF0_1 | PS.base.c5 | WS.003.3a in room 003 -> - | - + PF0_1 | PS.base.c6 | WS.003.3b in room 003 -> - | - (18 rows) -QUERY: select * from PField_v1 where pfname = 'PF0_2' order by slotname; -pfname|slotname |backside |patch -------+--------------------+------------------------------+---------------------------------------------------------------------- -PF0_2 |PS.base.ta1 |Phone line -0 (Central call) |PS.base.a1 -> WS.001.1a in room 001 -> Phone PH.hc001 (Hicom standard) -PF0_2 |PS.base.ta2 |Phone line -501 (Fax entrance)|PS.base.a3 -> WS.001.2a in room 001 -> Phone PH.fax001 (Canon fax) -PF0_2 |PS.base.ta3 |Phone line -102 |- -PF0_2 |PS.base.ta4 |- |- -PF0_2 |PS.base.ta5 |Phone line -103 |PS.base.b1 -> WS.002.1a in room 002 -> Phone PH.hc002 (Hicom standard) -PF0_2 |PS.base.ta6 |Phone line -104 |- -PF0_2 |PS.base.tb1 |- |- -PF0_2 |PS.base.tb2 |Phone line -106 |PS.base.b3 -> WS.002.2a in room 002 -> Phone PH.hc003 (Hicom standard) -PF0_2 |PS.base.tb3 |Phone line -108 |- -PF0_2 |PS.base.tb4 |Phone line -109 |- -PF0_2 |PS.base.tb5 |Phone line -121 |- -PF0_2 |PS.base.tb6 |Phone line -122 |- +select * from PField_v1 where pfname = 'PF0_2' order by slotname; + pfname | slotname | backside | patch +--------+----------------------+--------------------------------+------------------------------------------------------------------------ + PF0_2 | PS.base.ta1 | Phone line -0 (Central call) | PS.base.a1 -> WS.001.1a in room 001 -> Phone PH.hc001 (Hicom standard) + PF0_2 | PS.base.ta2 | Phone line -501 (Fax entrance) | PS.base.a3 -> WS.001.2a in room 001 -> Phone PH.fax001 (Canon fax) + PF0_2 | PS.base.ta3 | Phone line -102 | - + PF0_2 | PS.base.ta4 | - | - + PF0_2 | PS.base.ta5 | Phone line -103 | PS.base.b1 -> WS.002.1a in room 002 -> Phone PH.hc002 (Hicom standard) + PF0_2 | PS.base.ta6 | Phone line -104 | - + PF0_2 | PS.base.tb1 | - | - + PF0_2 | PS.base.tb2 | Phone line -106 | PS.base.b3 -> WS.002.2a in room 002 -> Phone PH.hc003 (Hicom standard) + PF0_2 | PS.base.tb3 | Phone line -108 | - + PF0_2 | PS.base.tb4 | Phone line -109 | - + PF0_2 | PS.base.tb5 | Phone line -121 | - + PF0_2 | PS.base.tb6 | Phone line -122 | - (12 rows) -QUERY: insert into PField values ('PF1_1', 'should fail due to unique index'); +-- +-- Finally we want errors +-- +insert into PField values ('PF1_1', 'should fail due to unique index'); ERROR: Cannot insert a duplicate key into unique index pfield_name -QUERY: update PSlot set backlink = 'WS.not.there' where slotname = 'PS.base.a1'; +update PSlot set backlink = 'WS.not.there' where slotname = 'PS.base.a1'; ERROR: WS.not.there does not exists -QUERY: update PSlot set backlink = 'XX.illegal' where slotname = 'PS.base.a1'; +update PSlot set backlink = 'XX.illegal' where slotname = 'PS.base.a1'; ERROR: illegal backlink beginning with XX -QUERY: update PSlot set slotlink = 'PS.not.there' where slotname = 'PS.base.a1'; +update PSlot set slotlink = 'PS.not.there' where slotname = 'PS.base.a1'; ERROR: PS.not.there does not exists -QUERY: update PSlot set slotlink = 'XX.illegal' where slotname = 'PS.base.a1'; +update PSlot set slotlink = 'XX.illegal' where slotname = 'PS.base.a1'; ERROR: illegal slotlink beginning with XX -QUERY: insert into HSlot values ('HS', 'base.hub1', 1, ''); +insert into HSlot values ('HS', 'base.hub1', 1, ''); ERROR: Cannot insert a duplicate key into unique index hslot_name -QUERY: insert into HSlot values ('HS', 'base.hub1', 20, ''); +insert into HSlot values ('HS', 'base.hub1', 20, ''); ERROR: no manual manipulation of HSlot -QUERY: delete from HSlot; +delete from HSlot; ERROR: no manual manipulation of HSlot -QUERY: insert into IFace values ('IF', 'notthere', 'eth0', ''); +insert into IFace values ('IF', 'notthere', 'eth0', ''); ERROR: system "notthere" does not exist -QUERY: insert into IFace values ('IF', 'orion', 'ethernet_interface_name_too_long', ''); +insert into IFace values ('IF', 'orion', 'ethernet_interface_name_too_long', ''); ERROR: IFace slotname "IF.orion.ethernet_interface_name_too_long" too long (20 char max) diff --git a/src/test/regress/expected/portals.out b/src/test/regress/expected/portals.out index a016a3c649..23c186cead 100644 --- a/src/test/regress/expected/portals.out +++ b/src/test/regress/expected/portals.out @@ -1,675 +1,678 @@ -QUERY: BEGIN; -QUERY: DECLARE foo1 CURSOR FOR SELECT * FROM tenk1; -QUERY: DECLARE foo2 CURSOR FOR SELECT * FROM tenk2; -QUERY: DECLARE foo3 CURSOR FOR SELECT * FROM tenk1; -QUERY: DECLARE foo4 CURSOR FOR SELECT * FROM tenk2; -QUERY: DECLARE foo5 CURSOR FOR SELECT * FROM tenk1; -QUERY: DECLARE foo6 CURSOR FOR SELECT * FROM tenk2; -QUERY: DECLARE foo7 CURSOR FOR SELECT * FROM tenk1; -QUERY: DECLARE foo8 CURSOR FOR SELECT * FROM tenk2; -QUERY: DECLARE foo9 CURSOR FOR SELECT * FROM tenk1; -QUERY: DECLARE foo10 CURSOR FOR SELECT * FROM tenk2; -QUERY: DECLARE foo11 CURSOR FOR SELECT * FROM tenk1; -QUERY: DECLARE foo12 CURSOR FOR SELECT * FROM tenk2; -QUERY: DECLARE foo13 CURSOR FOR SELECT * FROM tenk1; -QUERY: DECLARE foo14 CURSOR FOR SELECT * FROM tenk2; -QUERY: DECLARE foo15 CURSOR FOR SELECT * FROM tenk1; -QUERY: DECLARE foo16 CURSOR FOR SELECT * FROM tenk2; -QUERY: DECLARE foo17 CURSOR FOR SELECT * FROM tenk1; -QUERY: DECLARE foo18 CURSOR FOR SELECT * FROM tenk2; -QUERY: DECLARE foo19 CURSOR FOR SELECT * FROM tenk1; -QUERY: DECLARE foo20 CURSOR FOR SELECT * FROM tenk2; -QUERY: DECLARE foo21 CURSOR FOR SELECT * FROM tenk1; -QUERY: DECLARE foo22 CURSOR FOR SELECT * FROM tenk2; -QUERY: DECLARE foo23 CURSOR FOR SELECT * FROM tenk1; -QUERY: FETCH 1 in foo1; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx +-- +-- PORTALS +-- +BEGIN; +DECLARE foo1 CURSOR FOR SELECT * FROM tenk1; +DECLARE foo2 CURSOR FOR SELECT * FROM tenk2; +DECLARE foo3 CURSOR FOR SELECT * FROM tenk1; +DECLARE foo4 CURSOR FOR SELECT * FROM tenk2; +DECLARE foo5 CURSOR FOR SELECT * FROM tenk1; +DECLARE foo6 CURSOR FOR SELECT * FROM tenk2; +DECLARE foo7 CURSOR FOR SELECT * FROM tenk1; +DECLARE foo8 CURSOR FOR SELECT * FROM tenk2; +DECLARE foo9 CURSOR FOR SELECT * FROM tenk1; +DECLARE foo10 CURSOR FOR SELECT * FROM tenk2; +DECLARE foo11 CURSOR FOR SELECT * FROM tenk1; +DECLARE foo12 CURSOR FOR SELECT * FROM tenk2; +DECLARE foo13 CURSOR FOR SELECT * FROM tenk1; +DECLARE foo14 CURSOR FOR SELECT * FROM tenk2; +DECLARE foo15 CURSOR FOR SELECT * FROM tenk1; +DECLARE foo16 CURSOR FOR SELECT * FROM tenk2; +DECLARE foo17 CURSOR FOR SELECT * FROM tenk1; +DECLARE foo18 CURSOR FOR SELECT * FROM tenk2; +DECLARE foo19 CURSOR FOR SELECT * FROM tenk1; +DECLARE foo20 CURSOR FOR SELECT * FROM tenk2; +DECLARE foo21 CURSOR FOR SELECT * FROM tenk1; +DECLARE foo22 CURSOR FOR SELECT * FROM tenk2; +DECLARE foo23 CURSOR FOR SELECT * FROM tenk1; +FETCH 1 in foo1; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx (1 row) -QUERY: FETCH 2 in foo2; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx +FETCH 2 in foo2; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx (2 rows) -QUERY: FETCH 3 in foo3; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx +FETCH 3 in foo3; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx (3 rows) -QUERY: FETCH 4 in foo4; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx +FETCH 4 in foo4; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx (4 rows) -QUERY: FETCH 5 in foo5; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx +FETCH 5 in foo5; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx (5 rows) -QUERY: FETCH 6 in foo6; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx +FETCH 6 in foo6; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx (6 rows) -QUERY: FETCH 7 in foo7; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx +FETCH 7 in foo7; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx (7 rows) -QUERY: FETCH 8 in foo8; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx +FETCH 8 in foo8; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx (8 rows) -QUERY: FETCH 9 in foo9; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx +FETCH 9 in foo9; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx (9 rows) -QUERY: FETCH 10 in foo10; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx +FETCH 10 in foo10; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx (10 rows) -QUERY: FETCH 11 in foo11; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx +FETCH 11 in foo11; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx (11 rows) -QUERY: FETCH 12 in foo12; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx +FETCH 12 in foo12; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx (12 rows) -QUERY: FETCH 13 in foo13; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx +FETCH 13 in foo13; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx (13 rows) -QUERY: FETCH 14 in foo14; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx +FETCH 14 in foo14; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx (14 rows) -QUERY: FETCH 15 in foo15; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx - 5471| 14| 1| 3| 1| 11| 71| 471| 1471| 471| 5471|142| 143|LCAAAA |OAAAAA |OOOOxx +FETCH 15 in foo15; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx + 5471 | 14 | 1 | 3 | 1 | 11 | 71 | 471 | 1471 | 471 | 5471 | 142 | 143 | LCAAAA | OAAAAA | OOOOxx (15 rows) -QUERY: FETCH 16 in foo16; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx - 5471| 14| 1| 3| 1| 11| 71| 471| 1471| 471| 5471|142| 143|LCAAAA |OAAAAA |OOOOxx - 5006| 15| 0| 2| 6| 6| 6| 6| 1006| 6| 5006| 12| 13|OKAAAA |PAAAAA |VVVVxx +FETCH 16 in foo16; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx + 5471 | 14 | 1 | 3 | 1 | 11 | 71 | 471 | 1471 | 471 | 5471 | 142 | 143 | LCAAAA | OAAAAA | OOOOxx + 5006 | 15 | 0 | 2 | 6 | 6 | 6 | 6 | 1006 | 6 | 5006 | 12 | 13 | OKAAAA | PAAAAA | VVVVxx (16 rows) -QUERY: FETCH 17 in foo17; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx - 5471| 14| 1| 3| 1| 11| 71| 471| 1471| 471| 5471|142| 143|LCAAAA |OAAAAA |OOOOxx - 5006| 15| 0| 2| 6| 6| 6| 6| 1006| 6| 5006| 12| 13|OKAAAA |PAAAAA |VVVVxx - 5387| 16| 1| 3| 7| 7| 87| 387| 1387| 387| 5387|174| 175|FZAAAA |QAAAAA |AAAAxx +FETCH 17 in foo17; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx + 5471 | 14 | 1 | 3 | 1 | 11 | 71 | 471 | 1471 | 471 | 5471 | 142 | 143 | LCAAAA | OAAAAA | OOOOxx + 5006 | 15 | 0 | 2 | 6 | 6 | 6 | 6 | 1006 | 6 | 5006 | 12 | 13 | OKAAAA | PAAAAA | VVVVxx + 5387 | 16 | 1 | 3 | 7 | 7 | 87 | 387 | 1387 | 387 | 5387 | 174 | 175 | FZAAAA | QAAAAA | AAAAxx (17 rows) -QUERY: FETCH 18 in foo18; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx - 5471| 14| 1| 3| 1| 11| 71| 471| 1471| 471| 5471|142| 143|LCAAAA |OAAAAA |OOOOxx - 5006| 15| 0| 2| 6| 6| 6| 6| 1006| 6| 5006| 12| 13|OKAAAA |PAAAAA |VVVVxx - 5387| 16| 1| 3| 7| 7| 87| 387| 1387| 387| 5387|174| 175|FZAAAA |QAAAAA |AAAAxx - 5785| 17| 1| 1| 5| 5| 85| 785| 1785| 785| 5785|170| 171|NOAAAA |RAAAAA |HHHHxx +FETCH 18 in foo18; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx + 5471 | 14 | 1 | 3 | 1 | 11 | 71 | 471 | 1471 | 471 | 5471 | 142 | 143 | LCAAAA | OAAAAA | OOOOxx + 5006 | 15 | 0 | 2 | 6 | 6 | 6 | 6 | 1006 | 6 | 5006 | 12 | 13 | OKAAAA | PAAAAA | VVVVxx + 5387 | 16 | 1 | 3 | 7 | 7 | 87 | 387 | 1387 | 387 | 5387 | 174 | 175 | FZAAAA | QAAAAA | AAAAxx + 5785 | 17 | 1 | 1 | 5 | 5 | 85 | 785 | 1785 | 785 | 5785 | 170 | 171 | NOAAAA | RAAAAA | HHHHxx (18 rows) -QUERY: FETCH 19 in foo19; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx - 5471| 14| 1| 3| 1| 11| 71| 471| 1471| 471| 5471|142| 143|LCAAAA |OAAAAA |OOOOxx - 5006| 15| 0| 2| 6| 6| 6| 6| 1006| 6| 5006| 12| 13|OKAAAA |PAAAAA |VVVVxx - 5387| 16| 1| 3| 7| 7| 87| 387| 1387| 387| 5387|174| 175|FZAAAA |QAAAAA |AAAAxx - 5785| 17| 1| 1| 5| 5| 85| 785| 1785| 785| 5785|170| 171|NOAAAA |RAAAAA |HHHHxx - 6621| 18| 1| 1| 1| 1| 21| 621| 621| 1621| 6621| 42| 43|RUAAAA |SAAAAA |OOOOxx +FETCH 19 in foo19; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx + 5471 | 14 | 1 | 3 | 1 | 11 | 71 | 471 | 1471 | 471 | 5471 | 142 | 143 | LCAAAA | OAAAAA | OOOOxx + 5006 | 15 | 0 | 2 | 6 | 6 | 6 | 6 | 1006 | 6 | 5006 | 12 | 13 | OKAAAA | PAAAAA | VVVVxx + 5387 | 16 | 1 | 3 | 7 | 7 | 87 | 387 | 1387 | 387 | 5387 | 174 | 175 | FZAAAA | QAAAAA | AAAAxx + 5785 | 17 | 1 | 1 | 5 | 5 | 85 | 785 | 1785 | 785 | 5785 | 170 | 171 | NOAAAA | RAAAAA | HHHHxx + 6621 | 18 | 1 | 1 | 1 | 1 | 21 | 621 | 621 | 1621 | 6621 | 42 | 43 | RUAAAA | SAAAAA | OOOOxx (19 rows) -QUERY: FETCH 20 in foo20; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx - 5471| 14| 1| 3| 1| 11| 71| 471| 1471| 471| 5471|142| 143|LCAAAA |OAAAAA |OOOOxx - 5006| 15| 0| 2| 6| 6| 6| 6| 1006| 6| 5006| 12| 13|OKAAAA |PAAAAA |VVVVxx - 5387| 16| 1| 3| 7| 7| 87| 387| 1387| 387| 5387|174| 175|FZAAAA |QAAAAA |AAAAxx - 5785| 17| 1| 1| 5| 5| 85| 785| 1785| 785| 5785|170| 171|NOAAAA |RAAAAA |HHHHxx - 6621| 18| 1| 1| 1| 1| 21| 621| 621| 1621| 6621| 42| 43|RUAAAA |SAAAAA |OOOOxx - 6969| 19| 1| 1| 9| 9| 69| 969| 969| 1969| 6969|138| 139|BIAAAA |TAAAAA |VVVVxx +FETCH 20 in foo20; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx + 5471 | 14 | 1 | 3 | 1 | 11 | 71 | 471 | 1471 | 471 | 5471 | 142 | 143 | LCAAAA | OAAAAA | OOOOxx + 5006 | 15 | 0 | 2 | 6 | 6 | 6 | 6 | 1006 | 6 | 5006 | 12 | 13 | OKAAAA | PAAAAA | VVVVxx + 5387 | 16 | 1 | 3 | 7 | 7 | 87 | 387 | 1387 | 387 | 5387 | 174 | 175 | FZAAAA | QAAAAA | AAAAxx + 5785 | 17 | 1 | 1 | 5 | 5 | 85 | 785 | 1785 | 785 | 5785 | 170 | 171 | NOAAAA | RAAAAA | HHHHxx + 6621 | 18 | 1 | 1 | 1 | 1 | 21 | 621 | 621 | 1621 | 6621 | 42 | 43 | RUAAAA | SAAAAA | OOOOxx + 6969 | 19 | 1 | 1 | 9 | 9 | 69 | 969 | 969 | 1969 | 6969 | 138 | 139 | BIAAAA | TAAAAA | VVVVxx (20 rows) -QUERY: FETCH 21 in foo21; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx - 5471| 14| 1| 3| 1| 11| 71| 471| 1471| 471| 5471|142| 143|LCAAAA |OAAAAA |OOOOxx - 5006| 15| 0| 2| 6| 6| 6| 6| 1006| 6| 5006| 12| 13|OKAAAA |PAAAAA |VVVVxx - 5387| 16| 1| 3| 7| 7| 87| 387| 1387| 387| 5387|174| 175|FZAAAA |QAAAAA |AAAAxx - 5785| 17| 1| 1| 5| 5| 85| 785| 1785| 785| 5785|170| 171|NOAAAA |RAAAAA |HHHHxx - 6621| 18| 1| 1| 1| 1| 21| 621| 621| 1621| 6621| 42| 43|RUAAAA |SAAAAA |OOOOxx - 6969| 19| 1| 1| 9| 9| 69| 969| 969| 1969| 6969|138| 139|BIAAAA |TAAAAA |VVVVxx - 9460| 20| 0| 0| 0| 0| 60| 460| 1460| 4460| 9460|120| 121|WZAAAA |UAAAAA |AAAAxx +FETCH 21 in foo21; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx + 5471 | 14 | 1 | 3 | 1 | 11 | 71 | 471 | 1471 | 471 | 5471 | 142 | 143 | LCAAAA | OAAAAA | OOOOxx + 5006 | 15 | 0 | 2 | 6 | 6 | 6 | 6 | 1006 | 6 | 5006 | 12 | 13 | OKAAAA | PAAAAA | VVVVxx + 5387 | 16 | 1 | 3 | 7 | 7 | 87 | 387 | 1387 | 387 | 5387 | 174 | 175 | FZAAAA | QAAAAA | AAAAxx + 5785 | 17 | 1 | 1 | 5 | 5 | 85 | 785 | 1785 | 785 | 5785 | 170 | 171 | NOAAAA | RAAAAA | HHHHxx + 6621 | 18 | 1 | 1 | 1 | 1 | 21 | 621 | 621 | 1621 | 6621 | 42 | 43 | RUAAAA | SAAAAA | OOOOxx + 6969 | 19 | 1 | 1 | 9 | 9 | 69 | 969 | 969 | 1969 | 6969 | 138 | 139 | BIAAAA | TAAAAA | VVVVxx + 9460 | 20 | 0 | 0 | 0 | 0 | 60 | 460 | 1460 | 4460 | 9460 | 120 | 121 | WZAAAA | UAAAAA | AAAAxx (21 rows) -QUERY: FETCH 22 in foo22; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx - 5471| 14| 1| 3| 1| 11| 71| 471| 1471| 471| 5471|142| 143|LCAAAA |OAAAAA |OOOOxx - 5006| 15| 0| 2| 6| 6| 6| 6| 1006| 6| 5006| 12| 13|OKAAAA |PAAAAA |VVVVxx - 5387| 16| 1| 3| 7| 7| 87| 387| 1387| 387| 5387|174| 175|FZAAAA |QAAAAA |AAAAxx - 5785| 17| 1| 1| 5| 5| 85| 785| 1785| 785| 5785|170| 171|NOAAAA |RAAAAA |HHHHxx - 6621| 18| 1| 1| 1| 1| 21| 621| 621| 1621| 6621| 42| 43|RUAAAA |SAAAAA |OOOOxx - 6969| 19| 1| 1| 9| 9| 69| 969| 969| 1969| 6969|138| 139|BIAAAA |TAAAAA |VVVVxx - 9460| 20| 0| 0| 0| 0| 60| 460| 1460| 4460| 9460|120| 121|WZAAAA |UAAAAA |AAAAxx - 59| 21| 1| 3| 9| 19| 59| 59| 59| 59| 59|118| 119|HCAAAA |VAAAAA |HHHHxx +FETCH 22 in foo22; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx + 5471 | 14 | 1 | 3 | 1 | 11 | 71 | 471 | 1471 | 471 | 5471 | 142 | 143 | LCAAAA | OAAAAA | OOOOxx + 5006 | 15 | 0 | 2 | 6 | 6 | 6 | 6 | 1006 | 6 | 5006 | 12 | 13 | OKAAAA | PAAAAA | VVVVxx + 5387 | 16 | 1 | 3 | 7 | 7 | 87 | 387 | 1387 | 387 | 5387 | 174 | 175 | FZAAAA | QAAAAA | AAAAxx + 5785 | 17 | 1 | 1 | 5 | 5 | 85 | 785 | 1785 | 785 | 5785 | 170 | 171 | NOAAAA | RAAAAA | HHHHxx + 6621 | 18 | 1 | 1 | 1 | 1 | 21 | 621 | 621 | 1621 | 6621 | 42 | 43 | RUAAAA | SAAAAA | OOOOxx + 6969 | 19 | 1 | 1 | 9 | 9 | 69 | 969 | 969 | 1969 | 6969 | 138 | 139 | BIAAAA | TAAAAA | VVVVxx + 9460 | 20 | 0 | 0 | 0 | 0 | 60 | 460 | 1460 | 4460 | 9460 | 120 | 121 | WZAAAA | UAAAAA | AAAAxx + 59 | 21 | 1 | 3 | 9 | 19 | 59 | 59 | 59 | 59 | 59 | 118 | 119 | HCAAAA | VAAAAA | HHHHxx (22 rows) -QUERY: FETCH 23 in foo23; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx - 5471| 14| 1| 3| 1| 11| 71| 471| 1471| 471| 5471|142| 143|LCAAAA |OAAAAA |OOOOxx - 5006| 15| 0| 2| 6| 6| 6| 6| 1006| 6| 5006| 12| 13|OKAAAA |PAAAAA |VVVVxx - 5387| 16| 1| 3| 7| 7| 87| 387| 1387| 387| 5387|174| 175|FZAAAA |QAAAAA |AAAAxx - 5785| 17| 1| 1| 5| 5| 85| 785| 1785| 785| 5785|170| 171|NOAAAA |RAAAAA |HHHHxx - 6621| 18| 1| 1| 1| 1| 21| 621| 621| 1621| 6621| 42| 43|RUAAAA |SAAAAA |OOOOxx - 6969| 19| 1| 1| 9| 9| 69| 969| 969| 1969| 6969|138| 139|BIAAAA |TAAAAA |VVVVxx - 9460| 20| 0| 0| 0| 0| 60| 460| 1460| 4460| 9460|120| 121|WZAAAA |UAAAAA |AAAAxx - 59| 21| 1| 3| 9| 19| 59| 59| 59| 59| 59|118| 119|HCAAAA |VAAAAA |HHHHxx - 8020| 22| 0| 0| 0| 0| 20| 20| 20| 3020| 8020| 40| 41|MWAAAA |WAAAAA |OOOOxx +FETCH 23 in foo23; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx + 5471 | 14 | 1 | 3 | 1 | 11 | 71 | 471 | 1471 | 471 | 5471 | 142 | 143 | LCAAAA | OAAAAA | OOOOxx + 5006 | 15 | 0 | 2 | 6 | 6 | 6 | 6 | 1006 | 6 | 5006 | 12 | 13 | OKAAAA | PAAAAA | VVVVxx + 5387 | 16 | 1 | 3 | 7 | 7 | 87 | 387 | 1387 | 387 | 5387 | 174 | 175 | FZAAAA | QAAAAA | AAAAxx + 5785 | 17 | 1 | 1 | 5 | 5 | 85 | 785 | 1785 | 785 | 5785 | 170 | 171 | NOAAAA | RAAAAA | HHHHxx + 6621 | 18 | 1 | 1 | 1 | 1 | 21 | 621 | 621 | 1621 | 6621 | 42 | 43 | RUAAAA | SAAAAA | OOOOxx + 6969 | 19 | 1 | 1 | 9 | 9 | 69 | 969 | 969 | 1969 | 6969 | 138 | 139 | BIAAAA | TAAAAA | VVVVxx + 9460 | 20 | 0 | 0 | 0 | 0 | 60 | 460 | 1460 | 4460 | 9460 | 120 | 121 | WZAAAA | UAAAAA | AAAAxx + 59 | 21 | 1 | 3 | 9 | 19 | 59 | 59 | 59 | 59 | 59 | 118 | 119 | HCAAAA | VAAAAA | HHHHxx + 8020 | 22 | 0 | 0 | 0 | 0 | 20 | 20 | 20 | 3020 | 8020 | 40 | 41 | MWAAAA | WAAAAA | OOOOxx (23 rows) -QUERY: FETCH backward 1 in foo23; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 59| 21| 1| 3| 9| 19| 59| 59| 59| 59| 59|118| 119|HCAAAA |VAAAAA |HHHHxx +FETCH backward 1 in foo23; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 59 | 21 | 1 | 3 | 9 | 19 | 59 | 59 | 59 | 59 | 59 | 118 | 119 | HCAAAA | VAAAAA | HHHHxx (1 row) -QUERY: FETCH backward 2 in foo22; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 9460| 20| 0| 0| 0| 0| 60| 460| 1460| 4460| 9460|120| 121|WZAAAA |UAAAAA |AAAAxx - 6969| 19| 1| 1| 9| 9| 69| 969| 969| 1969| 6969|138| 139|BIAAAA |TAAAAA |VVVVxx +FETCH backward 2 in foo22; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 9460 | 20 | 0 | 0 | 0 | 0 | 60 | 460 | 1460 | 4460 | 9460 | 120 | 121 | WZAAAA | UAAAAA | AAAAxx + 6969 | 19 | 1 | 1 | 9 | 9 | 69 | 969 | 969 | 1969 | 6969 | 138 | 139 | BIAAAA | TAAAAA | VVVVxx (2 rows) -QUERY: FETCH backward 3 in foo21; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 6969| 19| 1| 1| 9| 9| 69| 969| 969| 1969| 6969|138| 139|BIAAAA |TAAAAA |VVVVxx - 6621| 18| 1| 1| 1| 1| 21| 621| 621| 1621| 6621| 42| 43|RUAAAA |SAAAAA |OOOOxx - 5785| 17| 1| 1| 5| 5| 85| 785| 1785| 785| 5785|170| 171|NOAAAA |RAAAAA |HHHHxx +FETCH backward 3 in foo21; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 6969 | 19 | 1 | 1 | 9 | 9 | 69 | 969 | 969 | 1969 | 6969 | 138 | 139 | BIAAAA | TAAAAA | VVVVxx + 6621 | 18 | 1 | 1 | 1 | 1 | 21 | 621 | 621 | 1621 | 6621 | 42 | 43 | RUAAAA | SAAAAA | OOOOxx + 5785 | 17 | 1 | 1 | 5 | 5 | 85 | 785 | 1785 | 785 | 5785 | 170 | 171 | NOAAAA | RAAAAA | HHHHxx (3 rows) -QUERY: FETCH backward 4 in foo20; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 6621| 18| 1| 1| 1| 1| 21| 621| 621| 1621| 6621| 42| 43|RUAAAA |SAAAAA |OOOOxx - 5785| 17| 1| 1| 5| 5| 85| 785| 1785| 785| 5785|170| 171|NOAAAA |RAAAAA |HHHHxx - 5387| 16| 1| 3| 7| 7| 87| 387| 1387| 387| 5387|174| 175|FZAAAA |QAAAAA |AAAAxx - 5006| 15| 0| 2| 6| 6| 6| 6| 1006| 6| 5006| 12| 13|OKAAAA |PAAAAA |VVVVxx +FETCH backward 4 in foo20; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 6621 | 18 | 1 | 1 | 1 | 1 | 21 | 621 | 621 | 1621 | 6621 | 42 | 43 | RUAAAA | SAAAAA | OOOOxx + 5785 | 17 | 1 | 1 | 5 | 5 | 85 | 785 | 1785 | 785 | 5785 | 170 | 171 | NOAAAA | RAAAAA | HHHHxx + 5387 | 16 | 1 | 3 | 7 | 7 | 87 | 387 | 1387 | 387 | 5387 | 174 | 175 | FZAAAA | QAAAAA | AAAAxx + 5006 | 15 | 0 | 2 | 6 | 6 | 6 | 6 | 1006 | 6 | 5006 | 12 | 13 | OKAAAA | PAAAAA | VVVVxx (4 rows) -QUERY: FETCH backward 5 in foo19; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 5785| 17| 1| 1| 5| 5| 85| 785| 1785| 785| 5785|170| 171|NOAAAA |RAAAAA |HHHHxx - 5387| 16| 1| 3| 7| 7| 87| 387| 1387| 387| 5387|174| 175|FZAAAA |QAAAAA |AAAAxx - 5006| 15| 0| 2| 6| 6| 6| 6| 1006| 6| 5006| 12| 13|OKAAAA |PAAAAA |VVVVxx - 5471| 14| 1| 3| 1| 11| 71| 471| 1471| 471| 5471|142| 143|LCAAAA |OAAAAA |OOOOxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx +FETCH backward 5 in foo19; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 5785 | 17 | 1 | 1 | 5 | 5 | 85 | 785 | 1785 | 785 | 5785 | 170 | 171 | NOAAAA | RAAAAA | HHHHxx + 5387 | 16 | 1 | 3 | 7 | 7 | 87 | 387 | 1387 | 387 | 5387 | 174 | 175 | FZAAAA | QAAAAA | AAAAxx + 5006 | 15 | 0 | 2 | 6 | 6 | 6 | 6 | 1006 | 6 | 5006 | 12 | 13 | OKAAAA | PAAAAA | VVVVxx + 5471 | 14 | 1 | 3 | 1 | 11 | 71 | 471 | 1471 | 471 | 5471 | 142 | 143 | LCAAAA | OAAAAA | OOOOxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx (5 rows) -QUERY: FETCH backward 6 in foo18; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 5387| 16| 1| 3| 7| 7| 87| 387| 1387| 387| 5387|174| 175|FZAAAA |QAAAAA |AAAAxx - 5006| 15| 0| 2| 6| 6| 6| 6| 1006| 6| 5006| 12| 13|OKAAAA |PAAAAA |VVVVxx - 5471| 14| 1| 3| 1| 11| 71| 471| 1471| 471| 5471|142| 143|LCAAAA |OAAAAA |OOOOxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx +FETCH backward 6 in foo18; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 5387 | 16 | 1 | 3 | 7 | 7 | 87 | 387 | 1387 | 387 | 5387 | 174 | 175 | FZAAAA | QAAAAA | AAAAxx + 5006 | 15 | 0 | 2 | 6 | 6 | 6 | 6 | 1006 | 6 | 5006 | 12 | 13 | OKAAAA | PAAAAA | VVVVxx + 5471 | 14 | 1 | 3 | 1 | 11 | 71 | 471 | 1471 | 471 | 5471 | 142 | 143 | LCAAAA | OAAAAA | OOOOxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx (6 rows) -QUERY: FETCH backward 7 in foo17; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 5006| 15| 0| 2| 6| 6| 6| 6| 1006| 6| 5006| 12| 13|OKAAAA |PAAAAA |VVVVxx - 5471| 14| 1| 3| 1| 11| 71| 471| 1471| 471| 5471|142| 143|LCAAAA |OAAAAA |OOOOxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx +FETCH backward 7 in foo17; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 5006 | 15 | 0 | 2 | 6 | 6 | 6 | 6 | 1006 | 6 | 5006 | 12 | 13 | OKAAAA | PAAAAA | VVVVxx + 5471 | 14 | 1 | 3 | 1 | 11 | 71 | 471 | 1471 | 471 | 5471 | 142 | 143 | LCAAAA | OAAAAA | OOOOxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx (7 rows) -QUERY: FETCH backward 8 in foo16; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 5471| 14| 1| 3| 1| 11| 71| 471| 1471| 471| 5471|142| 143|LCAAAA |OAAAAA |OOOOxx - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx +FETCH backward 8 in foo16; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 5471 | 14 | 1 | 3 | 1 | 11 | 71 | 471 | 1471 | 471 | 5471 | 142 | 143 | LCAAAA | OAAAAA | OOOOxx + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx (8 rows) -QUERY: FETCH backward 9 in foo15; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 6243| 13| 1| 3| 3| 3| 43| 243| 243| 1243| 6243| 86| 87|DGAAAA |NAAAAA |HHHHxx - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx +FETCH backward 9 in foo15; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 6243 | 13 | 1 | 3 | 3 | 3 | 43 | 243 | 243 | 1243 | 6243 | 86 | 87 | DGAAAA | NAAAAA | HHHHxx + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx (9 rows) -QUERY: FETCH backward 10 in foo14; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 5222| 12| 0| 2| 2| 2| 22| 222| 1222| 222| 5222| 44| 45|WSAAAA |MAAAAA |AAAAxx - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx +FETCH backward 10 in foo14; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 5222 | 12 | 0 | 2 | 2 | 2 | 22 | 222 | 1222 | 222 | 5222 | 44 | 45 | WSAAAA | MAAAAA | AAAAxx + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx (10 rows) -QUERY: FETCH backward 11 in foo13; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 1504| 11| 0| 0| 4| 4| 4| 504| 1504| 1504| 1504| 8| 9|WFAAAA |LAAAAA |VVVVxx - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx +FETCH backward 11 in foo13; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 1504 | 11 | 0 | 0 | 4 | 4 | 4 | 504 | 1504 | 1504 | 1504 | 8 | 9 | WFAAAA | LAAAAA | VVVVxx + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx (11 rows) -QUERY: FETCH backward 12 in foo12; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 1314| 10| 0| 2| 4| 14| 14| 314| 1314| 1314| 1314| 28| 29|OYAAAA |KAAAAA |OOOOxx - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx +FETCH backward 12 in foo12; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 1314 | 10 | 0 | 2 | 4 | 14 | 14 | 314 | 1314 | 1314 | 1314 | 28 | 29 | OYAAAA | KAAAAA | OOOOxx + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx (11 rows) -QUERY: FETCH backward 13 in foo11; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 3043| 9| 1| 3| 3| 3| 43| 43| 1043| 3043| 3043| 86| 87|BNAAAA |JAAAAA |HHHHxx - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx +FETCH backward 13 in foo11; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 3043 | 9 | 1 | 3 | 3 | 3 | 43 | 43 | 1043 | 3043 | 3043 | 86 | 87 | BNAAAA | JAAAAA | HHHHxx + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx (10 rows) -QUERY: FETCH backward 14 in foo10; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 4321| 8| 1| 1| 1| 1| 21| 321| 321| 4321| 4321| 42| 43|FKAAAA |IAAAAA |AAAAxx - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx +FETCH backward 14 in foo10; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 4321 | 8 | 1 | 1 | 1 | 1 | 21 | 321 | 321 | 4321 | 4321 | 42 | 43 | FKAAAA | IAAAAA | AAAAxx + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx (9 rows) -QUERY: FETCH backward 15 in foo9; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 6701| 7| 1| 1| 1| 1| 1| 701| 701| 1701| 6701| 2| 3|TXAAAA |HAAAAA |VVVVxx - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx +FETCH backward 15 in foo9; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 6701 | 7 | 1 | 1 | 1 | 1 | 1 | 701 | 701 | 1701 | 6701 | 2 | 3 | TXAAAA | HAAAAA | VVVVxx + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx (8 rows) -QUERY: FETCH backward 16 in foo8; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 5057| 6| 1| 1| 7| 17| 57| 57| 1057| 57| 5057|114| 115|NMAAAA |GAAAAA |OOOOxx - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx +FETCH backward 16 in foo8; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 5057 | 6 | 1 | 1 | 7 | 17 | 57 | 57 | 1057 | 57 | 5057 | 114 | 115 | NMAAAA | GAAAAA | OOOOxx + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx (7 rows) -QUERY: FETCH backward 17 in foo7; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8009| 5| 1| 1| 9| 9| 9| 9| 9| 3009| 8009| 18| 19|BWAAAA |FAAAAA |HHHHxx - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx +FETCH backward 17 in foo7; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8009 | 5 | 1 | 1 | 9 | 9 | 9 | 9 | 9 | 3009 | 8009 | 18 | 19 | BWAAAA | FAAAAA | HHHHxx + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx (6 rows) -QUERY: FETCH backward 18 in foo6; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 7164| 4| 0| 0| 4| 4| 64| 164| 1164| 2164| 7164|128| 129|OPAAAA |EAAAAA |AAAAxx - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx +FETCH backward 18 in foo6; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 7164 | 4 | 0 | 0 | 4 | 4 | 64 | 164 | 1164 | 2164 | 7164 | 128 | 129 | OPAAAA | EAAAAA | AAAAxx + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx (5 rows) -QUERY: FETCH backward 19 in foo5; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 9850| 3| 0| 2| 0| 10| 50| 850| 1850| 4850| 9850|100| 101|WOAAAA |DAAAAA |VVVVxx - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx +FETCH backward 19 in foo5; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 9850 | 3 | 0 | 2 | 0 | 10 | 50 | 850 | 1850 | 4850 | 9850 | 100 | 101 | WOAAAA | DAAAAA | VVVVxx + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx (4 rows) -QUERY: FETCH backward 20 in foo4; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 3420| 2| 0| 0| 0| 0| 20| 420| 1420| 3420| 3420| 40| 41|OBAAAA |CAAAAA |OOOOxx - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx +FETCH backward 20 in foo4; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 3420 | 2 | 0 | 0 | 0 | 0 | 20 | 420 | 1420 | 3420 | 3420 | 40 | 41 | OBAAAA | CAAAAA | OOOOxx + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx (3 rows) -QUERY: FETCH backward 21 in foo3; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 1891| 1| 1| 3| 1| 11| 91| 891| 1891| 1891| 1891|182| 183|TUAAAA |BAAAAA |HHHHxx - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx +FETCH backward 21 in foo3; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 1891 | 1 | 1 | 3 | 1 | 11 | 91 | 891 | 1891 | 1891 | 1891 | 182 | 183 | TUAAAA | BAAAAA | HHHHxx + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx (2 rows) -QUERY: FETCH backward 22 in foo2; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 8800| 0| 0| 0| 0| 0| 0| 800| 800| 3800| 8800| 0| 1|MAAAAA |AAAAAA |AAAAxx +FETCH backward 22 in foo2; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 8800 | 0 | 0 | 0 | 0 | 0 | 0 | 800 | 800 | 3800 | 8800 | 0 | 1 | MAAAAA | AAAAAA | AAAAxx (1 row) -QUERY: FETCH backward 23 in foo1; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- +FETCH backward 23 in foo1; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- (0 rows) -QUERY: CLOSE foo1; -QUERY: CLOSE foo2; -QUERY: CLOSE foo3; -QUERY: CLOSE foo4; -QUERY: CLOSE foo5; -QUERY: CLOSE foo6; -QUERY: CLOSE foo7; -QUERY: CLOSE foo8; -QUERY: CLOSE foo9; -QUERY: CLOSE foo10; -QUERY: CLOSE foo11; -QUERY: CLOSE foo12; -QUERY: end; +CLOSE foo1; +CLOSE foo2; +CLOSE foo3; +CLOSE foo4; +CLOSE foo5; +CLOSE foo6; +CLOSE foo7; +CLOSE foo8; +CLOSE foo9; +CLOSE foo10; +CLOSE foo11; +CLOSE foo12; +end; diff --git a/src/test/regress/expected/portals_p2.out b/src/test/regress/expected/portals_p2.out index 126b44b885..558397f5c9 100644 --- a/src/test/regress/expected/portals_p2.out +++ b/src/test/regress/expected/portals_p2.out @@ -1,119 +1,123 @@ -QUERY: BEGIN; -QUERY: DECLARE foo13 CURSOR FOR +-- +-- PORTALS_P2 +-- +-- EXTEND INDEX onek2_u1_prtl WHERE onek2.unique1 <= 60; +BEGIN; +DECLARE foo13 CURSOR FOR SELECT * FROM onek WHERE unique1 = 50; -QUERY: DECLARE foo14 CURSOR FOR +DECLARE foo14 CURSOR FOR SELECT * FROM onek WHERE unique1 = 51; -QUERY: DECLARE foo15 CURSOR FOR +DECLARE foo15 CURSOR FOR SELECT * FROM onek WHERE unique1 = 52; -QUERY: DECLARE foo16 CURSOR FOR +DECLARE foo16 CURSOR FOR SELECT * FROM onek WHERE unique1 = 53; -QUERY: DECLARE foo17 CURSOR FOR +DECLARE foo17 CURSOR FOR SELECT * FROM onek WHERE unique1 = 54; -QUERY: DECLARE foo18 CURSOR FOR +DECLARE foo18 CURSOR FOR SELECT * FROM onek WHERE unique1 = 55; -QUERY: DECLARE foo19 CURSOR FOR +DECLARE foo19 CURSOR FOR SELECT * FROM onek WHERE unique1 = 56; -QUERY: DECLARE foo20 CURSOR FOR +DECLARE foo20 CURSOR FOR SELECT * FROM onek WHERE unique1 = 57; -QUERY: DECLARE foo21 CURSOR FOR +DECLARE foo21 CURSOR FOR SELECT * FROM onek WHERE unique1 = 58; -QUERY: DECLARE foo22 CURSOR FOR +DECLARE foo22 CURSOR FOR SELECT * FROM onek WHERE unique1 = 59; -QUERY: DECLARE foo23 CURSOR FOR +DECLARE foo23 CURSOR FOR SELECT * FROM onek WHERE unique1 = 60; -QUERY: DECLARE foo24 CURSOR FOR +DECLARE foo24 CURSOR FOR SELECT * FROM onek2 WHERE unique1 = 50; -QUERY: DECLARE foo25 CURSOR FOR +DECLARE foo25 CURSOR FOR SELECT * FROM onek2 WHERE unique1 = 60; -QUERY: FETCH all in foo13; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 50| 253| 0| 2| 0| 10| 0| 50| 50| 50| 50| 0| 1|YBAAAA |TJAAAA |HHHHxx +FETCH all in foo13; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 50 | 253 | 0 | 2 | 0 | 10 | 0 | 50 | 50 | 50 | 50 | 0 | 1 | YBAAAA | TJAAAA | HHHHxx (1 row) -QUERY: FETCH all in foo14; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 51| 76| 1| 3| 1| 11| 1| 51| 51| 51| 51| 2| 3|ZBAAAA |YCAAAA |AAAAxx +FETCH all in foo14; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 51 | 76 | 1 | 3 | 1 | 11 | 1 | 51 | 51 | 51 | 51 | 2 | 3 | ZBAAAA | YCAAAA | AAAAxx (1 row) -QUERY: FETCH all in foo15; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 52| 985| 0| 0| 2| 12| 2| 52| 52| 52| 52| 4| 5|ACAAAA |XLBAAA |HHHHxx +FETCH all in foo15; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 52 | 985 | 0 | 0 | 2 | 12 | 2 | 52 | 52 | 52 | 52 | 4 | 5 | ACAAAA | XLBAAA | HHHHxx (1 row) -QUERY: FETCH all in foo16; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 53| 196| 1| 1| 3| 13| 3| 53| 53| 53| 53| 6| 7|BCAAAA |OHAAAA |AAAAxx +FETCH all in foo16; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 53 | 196 | 1 | 1 | 3 | 13 | 3 | 53 | 53 | 53 | 53 | 6 | 7 | BCAAAA | OHAAAA | AAAAxx (1 row) -QUERY: FETCH all in foo17; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 54| 356| 0| 2| 4| 14| 4| 54| 54| 54| 54| 8| 9|CCAAAA |SNAAAA |AAAAxx +FETCH all in foo17; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 54 | 356 | 0 | 2 | 4 | 14 | 4 | 54 | 54 | 54 | 54 | 8 | 9 | CCAAAA | SNAAAA | AAAAxx (1 row) -QUERY: FETCH all in foo18; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 55| 627| 1| 3| 5| 15| 5| 55| 55| 55| 55| 10| 11|DCAAAA |DYAAAA |VVVVxx +FETCH all in foo18; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 55 | 627 | 1 | 3 | 5 | 15 | 5 | 55 | 55 | 55 | 55 | 10 | 11 | DCAAAA | DYAAAA | VVVVxx (1 row) -QUERY: FETCH all in foo19; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 56| 54| 0| 0| 6| 16| 6| 56| 56| 56| 56| 12| 13|ECAAAA |CCAAAA |OOOOxx +FETCH all in foo19; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 56 | 54 | 0 | 0 | 6 | 16 | 6 | 56 | 56 | 56 | 56 | 12 | 13 | ECAAAA | CCAAAA | OOOOxx (1 row) -QUERY: FETCH all in foo20; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 57| 942| 1| 1| 7| 17| 7| 57| 57| 57| 57| 14| 15|FCAAAA |GKBAAA |OOOOxx +FETCH all in foo20; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 57 | 942 | 1 | 1 | 7 | 17 | 7 | 57 | 57 | 57 | 57 | 14 | 15 | FCAAAA | GKBAAA | OOOOxx (1 row) -QUERY: FETCH all in foo21; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 58| 114| 0| 2| 8| 18| 8| 58| 58| 58| 58| 16| 17|GCAAAA |KEAAAA |OOOOxx +FETCH all in foo21; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 58 | 114 | 0 | 2 | 8 | 18 | 8 | 58 | 58 | 58 | 58 | 16 | 17 | GCAAAA | KEAAAA | OOOOxx (1 row) -QUERY: FETCH all in foo22; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 59| 593| 1| 3| 9| 19| 9| 59| 59| 59| 59| 18| 19|HCAAAA |VWAAAA |HHHHxx +FETCH all in foo22; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 59 | 593 | 1 | 3 | 9 | 19 | 9 | 59 | 59 | 59 | 59 | 18 | 19 | HCAAAA | VWAAAA | HHHHxx (1 row) -QUERY: FETCH all in foo23; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 60| 483| 0| 0| 0| 0| 0| 60| 60| 60| 60| 0| 1|ICAAAA |PSAAAA |VVVVxx +FETCH all in foo23; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 60 | 483 | 0 | 0 | 0 | 0 | 0 | 60 | 60 | 60 | 60 | 0 | 1 | ICAAAA | PSAAAA | VVVVxx (1 row) -QUERY: FETCH all in foo24; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 50| 253| 0| 2| 0| 10| 0| 50| 50| 50| 50| 0| 1|YBAAAA |TJAAAA |HHHHxx +FETCH all in foo24; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 50 | 253 | 0 | 2 | 0 | 10 | 0 | 50 | 50 | 50 | 50 | 0 | 1 | YBAAAA | TJAAAA | HHHHxx (1 row) -QUERY: FETCH all in foo25; -unique1|unique2|two|four|ten|twenty|hundred|thousand|twothousand|fivethous|tenthous|odd|even|stringu1|stringu2|string4 --------+-------+---+----+---+------+-------+--------+-----------+---------+--------+---+----+--------+--------+------- - 60| 483| 0| 0| 0| 0| 0| 60| 60| 60| 60| 0| 1|ICAAAA |PSAAAA |VVVVxx +FETCH all in foo25; + unique1 | unique2 | two | four | ten | twenty | hundred | thousand | twothousand | fivethous | tenthous | odd | even | stringu1 | stringu2 | string4 +---------+---------+-----+------+-----+--------+---------+----------+-------------+-----------+----------+-----+------+----------+----------+--------- + 60 | 483 | 0 | 0 | 0 | 0 | 0 | 60 | 60 | 60 | 60 | 0 | 1 | ICAAAA | PSAAAA | VVVVxx (1 row) -QUERY: CLOSE foo13; -QUERY: CLOSE foo14; -QUERY: CLOSE foo15; -QUERY: CLOSE foo16; -QUERY: CLOSE foo17; -QUERY: CLOSE foo18; -QUERY: CLOSE foo19; -QUERY: CLOSE foo20; -QUERY: CLOSE foo21; -QUERY: CLOSE foo22; -QUERY: CLOSE foo23; -QUERY: CLOSE foo24; -QUERY: CLOSE foo25; -QUERY: END; +CLOSE foo13; +CLOSE foo14; +CLOSE foo15; +CLOSE foo16; +CLOSE foo17; +CLOSE foo18; +CLOSE foo19; +CLOSE foo20; +CLOSE foo21; +CLOSE foo22; +CLOSE foo23; +CLOSE foo24; +CLOSE foo25; +END; diff --git a/src/test/regress/expected/rules.out b/src/test/regress/expected/rules.out index ccf5ffd433..9449241db8 100644 --- a/src/test/regress/expected/rules.out +++ b/src/test/regress/expected/rules.out @@ -1,874 +1,949 @@ -QUERY: create table rtest_t1 (a int4, b int4); -QUERY: create table rtest_t2 (a int4, b int4); -QUERY: create table rtest_t3 (a int4, b int4); -QUERY: create view rtest_v1 as select * from rtest_t1; -QUERY: create rule rtest_v1_ins as on insert to rtest_v1 do instead +-- +-- RULES +-- From Jan's original setup_ruletest.sql and run_ruletest.sql +-- - thomas 1998-09-13 +-- +-- +-- Tables and rules for the view test +-- +create table rtest_t1 (a int4, b int4); +create table rtest_t2 (a int4, b int4); +create table rtest_t3 (a int4, b int4); +create view rtest_v1 as select * from rtest_t1; +create rule rtest_v1_ins as on insert to rtest_v1 do instead insert into rtest_t1 values (new.a, new.b); -QUERY: create rule rtest_v1_upd as on update to rtest_v1 do instead +create rule rtest_v1_upd as on update to rtest_v1 do instead update rtest_t1 set a = new.a, b = new.b where a = old.a; -QUERY: create rule rtest_v1_del as on delete to rtest_v1 do instead +create rule rtest_v1_del as on delete to rtest_v1 do instead delete from rtest_t1 where a = old.a; -QUERY: create table rtest_system (sysname text, sysdesc text); -QUERY: create table rtest_interface (sysname text, ifname text); -QUERY: create table rtest_person (pname text, pdesc text); -QUERY: create table rtest_admin (pname text, sysname text); -QUERY: create rule rtest_sys_upd as on update to rtest_system do ( - update rtest_interface set sysname = new.sysname +-- +-- Tables and rules for the constraint update/delete test +-- +-- Note: +-- Now that we have multiple action rule support, we check +-- both possible syntaxes to define them (The last action +-- can but must not have a semicolon at the end). +-- +create table rtest_system (sysname text, sysdesc text); +create table rtest_interface (sysname text, ifname text); +create table rtest_person (pname text, pdesc text); +create table rtest_admin (pname text, sysname text); +create rule rtest_sys_upd as on update to rtest_system do ( + update rtest_interface set sysname = new.sysname where sysname = old.sysname; - update rtest_admin set sysname = new.sysname + update rtest_admin set sysname = new.sysname where sysname = old.sysname ); -QUERY: create rule rtest_sys_del as on delete to rtest_system do ( +create rule rtest_sys_del as on delete to rtest_system do ( delete from rtest_interface where sysname = old.sysname; delete from rtest_admin where sysname = old.sysname; ); -QUERY: create rule rtest_pers_upd as on update to rtest_person do +create rule rtest_pers_upd as on update to rtest_person do update rtest_admin set pname = new.pname where pname = old.pname; -QUERY: create rule rtest_pers_del as on delete to rtest_person do +create rule rtest_pers_del as on delete to rtest_person do delete from rtest_admin where pname = old.pname; -QUERY: create table rtest_emp (ename char(20), salary money); -QUERY: create table rtest_emplog (ename char(20), who name, action char(10), newsal money, oldsal money); -QUERY: create table rtest_empmass (ename char(20), salary money); -QUERY: create rule rtest_emp_ins as on insert to rtest_emp do +-- +-- Tables and rules for the logging test +-- +create table rtest_emp (ename char(20), salary money); +create table rtest_emplog (ename char(20), who name, action char(10), newsal money, oldsal money); +create table rtest_empmass (ename char(20), salary money); +create rule rtest_emp_ins as on insert to rtest_emp do insert into rtest_emplog values (new.ename, current_user, 'hired', new.salary, '0.00'); -QUERY: create rule rtest_emp_upd as on update to rtest_emp where new.salary != old.salary do +create rule rtest_emp_upd as on update to rtest_emp where new.salary != old.salary do insert into rtest_emplog values (new.ename, current_user, 'honored', new.salary, old.salary); -QUERY: create rule rtest_emp_del as on delete to rtest_emp do +create rule rtest_emp_del as on delete to rtest_emp do insert into rtest_emplog values (old.ename, current_user, 'fired', '0.00', old.salary); -QUERY: create table rtest_t4 (a int4, b text); -QUERY: create table rtest_t5 (a int4, b text); -QUERY: create table rtest_t6 (a int4, b text); -QUERY: create table rtest_t7 (a int4, b text); -QUERY: create table rtest_t8 (a int4, b text); -QUERY: create table rtest_t9 (a int4, b text); -QUERY: create rule rtest_t4_ins1 as on insert to rtest_t4 +-- +-- Tables and rules for the multiple cascaded qualified instead +-- rule test +-- +create table rtest_t4 (a int4, b text); +create table rtest_t5 (a int4, b text); +create table rtest_t6 (a int4, b text); +create table rtest_t7 (a int4, b text); +create table rtest_t8 (a int4, b text); +create table rtest_t9 (a int4, b text); +create rule rtest_t4_ins1 as on insert to rtest_t4 where new.a >= 10 and new.a < 20 do instead insert into rtest_t5 values (new.a, new.b); -QUERY: create rule rtest_t4_ins2 as on insert to rtest_t4 +create rule rtest_t4_ins2 as on insert to rtest_t4 where new.a >= 20 and new.a < 30 do insert into rtest_t6 values (new.a, new.b); -QUERY: create rule rtest_t5_ins as on insert to rtest_t5 +create rule rtest_t5_ins as on insert to rtest_t5 where new.a > 15 do insert into rtest_t7 values (new.a, new.b); -QUERY: create rule rtest_t6_ins as on insert to rtest_t6 +create rule rtest_t6_ins as on insert to rtest_t6 where new.a > 25 do instead insert into rtest_t8 values (new.a, new.b); -QUERY: create table rtest_order1 (a int4); -QUERY: create table rtest_order2 (a int4, b int4, c text); -QUERY: create sequence rtest_seq; -QUERY: create rule rtest_order_r3 as on insert to rtest_order1 do instead +-- +-- Tables and rules for the rule fire order test +-- +create table rtest_order1 (a int4); +create table rtest_order2 (a int4, b int4, c text); +create sequence rtest_seq; +create rule rtest_order_r3 as on insert to rtest_order1 do instead insert into rtest_order2 values (new.a, nextval('rtest_seq'), 'rule 3 - this should run 3rd or 4th'); -QUERY: create rule rtest_order_r4 as on insert to rtest_order1 +create rule rtest_order_r4 as on insert to rtest_order1 where a < 100 do instead insert into rtest_order2 values (new.a, nextval('rtest_seq'), 'rule 4 - this should run 2nd'); -QUERY: create rule rtest_order_r2 as on insert to rtest_order1 do +create rule rtest_order_r2 as on insert to rtest_order1 do insert into rtest_order2 values (new.a, nextval('rtest_seq'), 'rule 2 - this should run 1st'); -QUERY: create rule rtest_order_r1 as on insert to rtest_order1 do instead +create rule rtest_order_r1 as on insert to rtest_order1 do instead insert into rtest_order2 values (new.a, nextval('rtest_seq'), 'rule 1 - this should run 3rd or 4th'); -QUERY: create table rtest_nothn1 (a int4, b text); -QUERY: create table rtest_nothn2 (a int4, b text); -QUERY: create table rtest_nothn3 (a int4, b text); -QUERY: create table rtest_nothn4 (a int4, b text); -QUERY: create rule rtest_nothn_r1 as on insert to rtest_nothn1 +-- +-- Tables and rules for the instead nothing test +-- +create table rtest_nothn1 (a int4, b text); +create table rtest_nothn2 (a int4, b text); +create table rtest_nothn3 (a int4, b text); +create table rtest_nothn4 (a int4, b text); +create rule rtest_nothn_r1 as on insert to rtest_nothn1 where new.a >= 10 and new.a < 20 do instead (select 1); -QUERY: create rule rtest_nothn_r2 as on insert to rtest_nothn1 +create rule rtest_nothn_r2 as on insert to rtest_nothn1 where new.a >= 30 and new.a < 40 do instead nothing; -QUERY: create rule rtest_nothn_r3 as on insert to rtest_nothn2 +create rule rtest_nothn_r3 as on insert to rtest_nothn2 where new.a >= 100 do instead insert into rtest_nothn3 values (new.a, new.b); -QUERY: create rule rtest_nothn_r4 as on insert to rtest_nothn2 +create rule rtest_nothn_r4 as on insert to rtest_nothn2 do instead nothing; -QUERY: insert into rtest_t2 values (1, 21); -QUERY: insert into rtest_t2 values (2, 22); -QUERY: insert into rtest_t2 values (3, 23); -QUERY: insert into rtest_t3 values (1, 31); -QUERY: insert into rtest_t3 values (2, 32); -QUERY: insert into rtest_t3 values (3, 33); -QUERY: insert into rtest_t3 values (4, 34); -QUERY: insert into rtest_t3 values (5, 35); -QUERY: insert into rtest_v1 values (1, 11); -QUERY: insert into rtest_v1 values (2, 12); -QUERY: select * from rtest_v1; -a| b --+-- -1|11 -2|12 +-- +-- Tests on a view that is select * of a table +-- and has insert/update/delete instead rules to +-- behave close like the real table. +-- +-- +-- We need test date later +-- +insert into rtest_t2 values (1, 21); +insert into rtest_t2 values (2, 22); +insert into rtest_t2 values (3, 23); +insert into rtest_t3 values (1, 31); +insert into rtest_t3 values (2, 32); +insert into rtest_t3 values (3, 33); +insert into rtest_t3 values (4, 34); +insert into rtest_t3 values (5, 35); +-- insert values +insert into rtest_v1 values (1, 11); +insert into rtest_v1 values (2, 12); +select * from rtest_v1; + a | b +---+---- + 1 | 11 + 2 | 12 (2 rows) -QUERY: delete from rtest_v1 where a = 1; -QUERY: select * from rtest_v1; -a| b --+-- -2|12 +-- delete with constant expression +delete from rtest_v1 where a = 1; +select * from rtest_v1; + a | b +---+---- + 2 | 12 (1 row) -QUERY: insert into rtest_v1 values (1, 11); -QUERY: delete from rtest_v1 where b = 12; -QUERY: select * from rtest_v1; -a| b --+-- -1|11 +insert into rtest_v1 values (1, 11); +delete from rtest_v1 where b = 12; +select * from rtest_v1; + a | b +---+---- + 1 | 11 (1 row) -QUERY: insert into rtest_v1 values (2, 12); -QUERY: insert into rtest_v1 values (2, 13); -QUERY: select * from rtest_v1; -a| b --+-- -1|11 -2|12 -2|13 +insert into rtest_v1 values (2, 12); +insert into rtest_v1 values (2, 13); +select * from rtest_v1; + a | b +---+---- + 1 | 11 + 2 | 12 + 2 | 13 (3 rows) ** Remember the delete rule on rtest_v1: It says ** DO INSTEAD DELETE FROM rtest_t1 WHERE a = old.a ** So this time both rows with a = 2 must get deleted -QUERY: delete from rtest_v1 where b = 12; -QUERY: select * from rtest_v1; -a| b --+-- -1|11 +\p +** Remember the delete rule on rtest_v1: It says +** DO INSTEAD DELETE FROM rtest_t1 WHERE a = old.a +** So this time both rows with a = 2 must get deleted +\r +delete from rtest_v1 where b = 12; +select * from rtest_v1; + a | b +---+---- + 1 | 11 (1 row) -QUERY: delete from rtest_v1; -QUERY: insert into rtest_v1 select * from rtest_t2; -QUERY: select * from rtest_v1; -a| b --+-- -1|21 -2|22 -3|23 +delete from rtest_v1; +-- insert select +insert into rtest_v1 select * from rtest_t2; +select * from rtest_v1; + a | b +---+---- + 1 | 21 + 2 | 22 + 3 | 23 (3 rows) -QUERY: delete from rtest_v1; -QUERY: insert into rtest_v1 (b, a) select b, a from rtest_t2; -QUERY: select * from rtest_v1; -a| b --+-- -1|21 -2|22 -3|23 +delete from rtest_v1; +-- same with swapped targetlist +insert into rtest_v1 (b, a) select b, a from rtest_t2; +select * from rtest_v1; + a | b +---+---- + 1 | 21 + 2 | 22 + 3 | 23 (3 rows) -QUERY: insert into rtest_v1 (a) select a from rtest_t3; -QUERY: select * from rtest_v1; -a| b --+-- -1|21 -2|22 -3|23 -1| -2| -3| -4| -5| +-- now with only one target attribute +insert into rtest_v1 (a) select a from rtest_t3; +select * from rtest_v1; + a | b +---+---- + 1 | 21 + 2 | 22 + 3 | 23 + 1 | + 2 | + 3 | + 4 | + 5 | (8 rows) -QUERY: select * from rtest_v1 where b isnull; -a|b --+- -1| -2| -3| -4| -5| +select * from rtest_v1 where b isnull; + a | b +---+--- + 1 | + 2 | + 3 | + 4 | + 5 | (5 rows) -QUERY: update rtest_t1 set a = a + 10 where b isnull; -QUERY: delete from rtest_v1 where b isnull; -QUERY: select * from rtest_v1; -a| b --+-- -1|21 -2|22 -3|23 +-- let attribute a differ (must be done on rtest_t1 - see above) +update rtest_t1 set a = a + 10 where b isnull; +delete from rtest_v1 where b isnull; +select * from rtest_v1; + a | b +---+---- + 1 | 21 + 2 | 22 + 3 | 23 (3 rows) -QUERY: update rtest_v1 set b = 42 where a = 2; -QUERY: select * from rtest_v1; -a| b --+-- -1|21 -3|23 -2|42 +-- now updates with constant expression +update rtest_v1 set b = 42 where a = 2; +select * from rtest_v1; + a | b +---+---- + 1 | 21 + 3 | 23 + 2 | 42 (3 rows) -QUERY: update rtest_v1 set b = 99 where b = 42; -QUERY: select * from rtest_v1; -a| b --+-- -1|21 -3|23 -2|99 +update rtest_v1 set b = 99 where b = 42; +select * from rtest_v1; + a | b +---+---- + 1 | 21 + 3 | 23 + 2 | 99 (3 rows) -QUERY: update rtest_v1 set b = 88 where b < 50; -QUERY: select * from rtest_v1; -a| b --+-- -2|99 -1|88 -3|88 +update rtest_v1 set b = 88 where b < 50; +select * from rtest_v1; + a | b +---+---- + 2 | 99 + 1 | 88 + 3 | 88 (3 rows) -QUERY: delete from rtest_v1; -QUERY: insert into rtest_v1 select rtest_t2.a, rtest_t3.b where rtest_t2.a = rtest_t3.a; -QUERY: select * from rtest_v1; -a| b --+-- -1|31 -2|32 -3|33 +delete from rtest_v1; +insert into rtest_v1 select rtest_t2.a, rtest_t3.b where rtest_t2.a = rtest_t3.a; +select * from rtest_v1; + a | b +---+---- + 1 | 31 + 2 | 32 + 3 | 33 (3 rows) -QUERY: update rtest_v1 set b = rtest_t2.b where a = rtest_t2.a; -QUERY: select * from rtest_v1; -a| b --+-- -1|21 -2|22 -3|23 +-- updates in a mergejoin +update rtest_v1 set b = rtest_t2.b where a = rtest_t2.a; +select * from rtest_v1; + a | b +---+---- + 1 | 21 + 2 | 22 + 3 | 23 (3 rows) -QUERY: insert into rtest_v1 select * from rtest_t3; -QUERY: select * from rtest_v1; -a| b --+-- -1|21 -2|22 -3|23 -1|31 -2|32 -3|33 -4|34 -5|35 +insert into rtest_v1 select * from rtest_t3; +select * from rtest_v1; + a | b +---+---- + 1 | 21 + 2 | 22 + 3 | 23 + 1 | 31 + 2 | 32 + 3 | 33 + 4 | 34 + 5 | 35 (8 rows) -QUERY: update rtest_t1 set a = a + 10 where b > 30; -QUERY: select * from rtest_v1; - a| b ---+-- - 1|21 - 2|22 - 3|23 -11|31 -12|32 -13|33 -14|34 -15|35 +update rtest_t1 set a = a + 10 where b > 30; +select * from rtest_v1; + a | b +----+---- + 1 | 21 + 2 | 22 + 3 | 23 + 11 | 31 + 12 | 32 + 13 | 33 + 14 | 34 + 15 | 35 (8 rows) -QUERY: update rtest_v1 set a = rtest_t3.a + 20 where b = rtest_t3.b; -QUERY: select * from rtest_v1; - a| b ---+-- - 1|21 - 2|22 - 3|23 -21|31 -22|32 -23|33 -24|34 -25|35 +update rtest_v1 set a = rtest_t3.a + 20 where b = rtest_t3.b; +select * from rtest_v1; + a | b +----+---- + 1 | 21 + 2 | 22 + 3 | 23 + 21 | 31 + 22 | 32 + 23 | 33 + 24 | 34 + 25 | 35 (8 rows) -QUERY: insert into rtest_system values ('orion', 'Linux Jan Wieck'); -QUERY: insert into rtest_system values ('notjw', 'WinNT Jan Wieck (notebook)'); -QUERY: insert into rtest_system values ('neptun', 'Fileserver'); -QUERY: insert into rtest_interface values ('orion', 'eth0'); -QUERY: insert into rtest_interface values ('orion', 'eth1'); -QUERY: insert into rtest_interface values ('notjw', 'eth0'); -QUERY: insert into rtest_interface values ('neptun', 'eth0'); -QUERY: insert into rtest_person values ('jw', 'Jan Wieck'); -QUERY: insert into rtest_person values ('bm', 'Bruce Momjian'); -QUERY: insert into rtest_admin values ('jw', 'orion'); -QUERY: insert into rtest_admin values ('jw', 'notjw'); -QUERY: insert into rtest_admin values ('bm', 'neptun'); -QUERY: update rtest_system set sysname = 'pluto' where sysname = 'neptun'; -QUERY: select * from rtest_interface; -sysname|ifname --------+------ -orion |eth0 -orion |eth1 -notjw |eth0 -pluto |eth0 +-- +-- Test for constraint updates/deletes +-- +insert into rtest_system values ('orion', 'Linux Jan Wieck'); +insert into rtest_system values ('notjw', 'WinNT Jan Wieck (notebook)'); +insert into rtest_system values ('neptun', 'Fileserver'); +insert into rtest_interface values ('orion', 'eth0'); +insert into rtest_interface values ('orion', 'eth1'); +insert into rtest_interface values ('notjw', 'eth0'); +insert into rtest_interface values ('neptun', 'eth0'); +insert into rtest_person values ('jw', 'Jan Wieck'); +insert into rtest_person values ('bm', 'Bruce Momjian'); +insert into rtest_admin values ('jw', 'orion'); +insert into rtest_admin values ('jw', 'notjw'); +insert into rtest_admin values ('bm', 'neptun'); +update rtest_system set sysname = 'pluto' where sysname = 'neptun'; +select * from rtest_interface; + sysname | ifname +---------+-------- + orion | eth0 + orion | eth1 + notjw | eth0 + pluto | eth0 (4 rows) -QUERY: select * from rtest_admin; -pname|sysname ------+------- -jw |orion -jw |notjw -bm |pluto +select * from rtest_admin; + pname | sysname +-------+--------- + jw | orion + jw | notjw + bm | pluto (3 rows) -QUERY: update rtest_person set pname = 'jwieck' where pdesc = 'Jan Wieck'; -QUERY: select * from rtest_admin order by pname, sysname; -pname |sysname -------+------- -bm |pluto -jwieck|notjw -jwieck|orion +update rtest_person set pname = 'jwieck' where pdesc = 'Jan Wieck'; +-- Note: use ORDER BY here to ensure consistent output across all systems. +-- The above UPDATE affects two rows with equal keys, so they could be +-- updated in either order depending on the whim of the local qsort(). +select * from rtest_admin order by pname, sysname; + pname | sysname +--------+--------- + bm | pluto + jwieck | notjw + jwieck | orion (3 rows) -QUERY: delete from rtest_system where sysname = 'orion'; -QUERY: select * from rtest_interface; -sysname|ifname --------+------ -notjw |eth0 -pluto |eth0 +delete from rtest_system where sysname = 'orion'; +select * from rtest_interface; + sysname | ifname +---------+-------- + notjw | eth0 + pluto | eth0 (2 rows) -QUERY: select * from rtest_admin; -pname |sysname -------+------- -bm |pluto -jwieck|notjw +select * from rtest_admin; + pname | sysname +--------+--------- + bm | pluto + jwieck | notjw (2 rows) -QUERY: insert into rtest_emp values ('wiech', '5000.00'); -QUERY: insert into rtest_emp values ('gates', '80000.00'); -QUERY: update rtest_emp set ename = 'wiecx' where ename = 'wiech'; -QUERY: update rtest_emp set ename = 'wieck', salary = '6000.00' where ename = 'wiecx'; -QUERY: update rtest_emp set salary = '7000.00' where ename = 'wieck'; -QUERY: delete from rtest_emp where ename = 'gates'; -QUERY: select ename, who = current_user as "matches user", action, newsal, oldsal from rtest_emplog order by ename, action, newsal; -ename |matches user|action |newsal |oldsal ---------------------+------------+----------+----------+---------- -gates |t |fired |$0.00 |$80,000.00 -gates |t |hired |$80,000.00|$0.00 -wiech |t |hired |$5,000.00 |$0.00 -wieck |t |honored |$6,000.00 |$5,000.00 -wieck |t |honored |$7,000.00 |$6,000.00 +-- +-- Rule qualification test +-- +insert into rtest_emp values ('wiech', '5000.00'); +insert into rtest_emp values ('gates', '80000.00'); +update rtest_emp set ename = 'wiecx' where ename = 'wiech'; +update rtest_emp set ename = 'wieck', salary = '6000.00' where ename = 'wiecx'; +update rtest_emp set salary = '7000.00' where ename = 'wieck'; +delete from rtest_emp where ename = 'gates'; +select ename, who = current_user as "matches user", action, newsal, oldsal from rtest_emplog order by ename, action, newsal; + ename | matches user | action | newsal | oldsal +----------------------+--------------+------------+------------+------------ + gates | t | fired | $0.00 | $80,000.00 + gates | t | hired | $80,000.00 | $0.00 + wiech | t | hired | $5,000.00 | $0.00 + wieck | t | honored | $6,000.00 | $5,000.00 + wieck | t | honored | $7,000.00 | $6,000.00 (5 rows) -QUERY: insert into rtest_empmass values ('meyer', '4000.00'); -QUERY: insert into rtest_empmass values ('maier', '5000.00'); -QUERY: insert into rtest_empmass values ('mayr', '6000.00'); -QUERY: insert into rtest_emp select * from rtest_empmass; -QUERY: select ename, who = current_user as "matches user", action, newsal, oldsal from rtest_emplog order by ename, action, newsal; -ename |matches user|action |newsal |oldsal ---------------------+------------+----------+----------+---------- -gates |t |fired |$0.00 |$80,000.00 -gates |t |hired |$80,000.00|$0.00 -maier |t |hired |$5,000.00 |$0.00 -mayr |t |hired |$6,000.00 |$0.00 -meyer |t |hired |$4,000.00 |$0.00 -wiech |t |hired |$5,000.00 |$0.00 -wieck |t |honored |$6,000.00 |$5,000.00 -wieck |t |honored |$7,000.00 |$6,000.00 +insert into rtest_empmass values ('meyer', '4000.00'); +insert into rtest_empmass values ('maier', '5000.00'); +insert into rtest_empmass values ('mayr', '6000.00'); +insert into rtest_emp select * from rtest_empmass; +select ename, who = current_user as "matches user", action, newsal, oldsal from rtest_emplog order by ename, action, newsal; + ename | matches user | action | newsal | oldsal +----------------------+--------------+------------+------------+------------ + gates | t | fired | $0.00 | $80,000.00 + gates | t | hired | $80,000.00 | $0.00 + maier | t | hired | $5,000.00 | $0.00 + mayr | t | hired | $6,000.00 | $0.00 + meyer | t | hired | $4,000.00 | $0.00 + wiech | t | hired | $5,000.00 | $0.00 + wieck | t | honored | $6,000.00 | $5,000.00 + wieck | t | honored | $7,000.00 | $6,000.00 (8 rows) -QUERY: update rtest_empmass set salary = salary + '1000.00'; -QUERY: update rtest_emp set salary = rtest_empmass.salary where ename = rtest_empmass.ename; -QUERY: select ename, who = current_user as "matches user", action, newsal, oldsal from rtest_emplog order by ename, action, newsal; -ename |matches user|action |newsal |oldsal ---------------------+------------+----------+----------+---------- -gates |t |fired |$0.00 |$80,000.00 -gates |t |hired |$80,000.00|$0.00 -maier |t |hired |$5,000.00 |$0.00 -maier |t |honored |$6,000.00 |$5,000.00 -mayr |t |hired |$6,000.00 |$0.00 -mayr |t |honored |$7,000.00 |$6,000.00 -meyer |t |hired |$4,000.00 |$0.00 -meyer |t |honored |$5,000.00 |$4,000.00 -wiech |t |hired |$5,000.00 |$0.00 -wieck |t |honored |$6,000.00 |$5,000.00 -wieck |t |honored |$7,000.00 |$6,000.00 +update rtest_empmass set salary = salary + '1000.00'; +update rtest_emp set salary = rtest_empmass.salary where ename = rtest_empmass.ename; +select ename, who = current_user as "matches user", action, newsal, oldsal from rtest_emplog order by ename, action, newsal; + ename | matches user | action | newsal | oldsal +----------------------+--------------+------------+------------+------------ + gates | t | fired | $0.00 | $80,000.00 + gates | t | hired | $80,000.00 | $0.00 + maier | t | hired | $5,000.00 | $0.00 + maier | t | honored | $6,000.00 | $5,000.00 + mayr | t | hired | $6,000.00 | $0.00 + mayr | t | honored | $7,000.00 | $6,000.00 + meyer | t | hired | $4,000.00 | $0.00 + meyer | t | honored | $5,000.00 | $4,000.00 + wiech | t | hired | $5,000.00 | $0.00 + wieck | t | honored | $6,000.00 | $5,000.00 + wieck | t | honored | $7,000.00 | $6,000.00 (11 rows) -QUERY: delete from rtest_emp where ename = rtest_empmass.ename; -QUERY: select ename, who = current_user as "matches user", action, newsal, oldsal from rtest_emplog order by ename, action, newsal; -ename |matches user|action |newsal |oldsal ---------------------+------------+----------+----------+---------- -gates |t |fired |$0.00 |$80,000.00 -gates |t |hired |$80,000.00|$0.00 -maier |t |fired |$0.00 |$6,000.00 -maier |t |hired |$5,000.00 |$0.00 -maier |t |honored |$6,000.00 |$5,000.00 -mayr |t |fired |$0.00 |$7,000.00 -mayr |t |hired |$6,000.00 |$0.00 -mayr |t |honored |$7,000.00 |$6,000.00 -meyer |t |fired |$0.00 |$5,000.00 -meyer |t |hired |$4,000.00 |$0.00 -meyer |t |honored |$5,000.00 |$4,000.00 -wiech |t |hired |$5,000.00 |$0.00 -wieck |t |honored |$6,000.00 |$5,000.00 -wieck |t |honored |$7,000.00 |$6,000.00 +delete from rtest_emp where ename = rtest_empmass.ename; +select ename, who = current_user as "matches user", action, newsal, oldsal from rtest_emplog order by ename, action, newsal; + ename | matches user | action | newsal | oldsal +----------------------+--------------+------------+------------+------------ + gates | t | fired | $0.00 | $80,000.00 + gates | t | hired | $80,000.00 | $0.00 + maier | t | fired | $0.00 | $6,000.00 + maier | t | hired | $5,000.00 | $0.00 + maier | t | honored | $6,000.00 | $5,000.00 + mayr | t | fired | $0.00 | $7,000.00 + mayr | t | hired | $6,000.00 | $0.00 + mayr | t | honored | $7,000.00 | $6,000.00 + meyer | t | fired | $0.00 | $5,000.00 + meyer | t | hired | $4,000.00 | $0.00 + meyer | t | honored | $5,000.00 | $4,000.00 + wiech | t | hired | $5,000.00 | $0.00 + wieck | t | honored | $6,000.00 | $5,000.00 + wieck | t | honored | $7,000.00 | $6,000.00 (14 rows) -QUERY: insert into rtest_t4 values (1, 'Record should go to rtest_t4'); -QUERY: insert into rtest_t4 values (2, 'Record should go to rtest_t4'); -QUERY: insert into rtest_t4 values (10, 'Record should go to rtest_t5'); -QUERY: insert into rtest_t4 values (15, 'Record should go to rtest_t5'); -QUERY: insert into rtest_t4 values (19, 'Record should go to rtest_t5 and t7'); -QUERY: insert into rtest_t4 values (20, 'Record should go to rtest_t4 and t6'); -QUERY: insert into rtest_t4 values (26, 'Record should go to rtest_t4 and t8'); -QUERY: insert into rtest_t4 values (28, 'Record should go to rtest_t4 and t8'); -QUERY: insert into rtest_t4 values (30, 'Record should go to rtest_t4'); -QUERY: insert into rtest_t4 values (40, 'Record should go to rtest_t4'); -QUERY: select * from rtest_t4; - a|b ---+----------------------------------- - 1|Record should go to rtest_t4 - 2|Record should go to rtest_t4 -20|Record should go to rtest_t4 and t6 -26|Record should go to rtest_t4 and t8 -28|Record should go to rtest_t4 and t8 -30|Record should go to rtest_t4 -40|Record should go to rtest_t4 +-- +-- Multiple cascaded qualified instead rule test +-- +insert into rtest_t4 values (1, 'Record should go to rtest_t4'); +insert into rtest_t4 values (2, 'Record should go to rtest_t4'); +insert into rtest_t4 values (10, 'Record should go to rtest_t5'); +insert into rtest_t4 values (15, 'Record should go to rtest_t5'); +insert into rtest_t4 values (19, 'Record should go to rtest_t5 and t7'); +insert into rtest_t4 values (20, 'Record should go to rtest_t4 and t6'); +insert into rtest_t4 values (26, 'Record should go to rtest_t4 and t8'); +insert into rtest_t4 values (28, 'Record should go to rtest_t4 and t8'); +insert into rtest_t4 values (30, 'Record should go to rtest_t4'); +insert into rtest_t4 values (40, 'Record should go to rtest_t4'); +select * from rtest_t4; + a | b +----+------------------------------------- + 1 | Record should go to rtest_t4 + 2 | Record should go to rtest_t4 + 20 | Record should go to rtest_t4 and t6 + 26 | Record should go to rtest_t4 and t8 + 28 | Record should go to rtest_t4 and t8 + 30 | Record should go to rtest_t4 + 40 | Record should go to rtest_t4 (7 rows) -QUERY: select * from rtest_t5; - a|b ---+----------------------------------- -10|Record should go to rtest_t5 -15|Record should go to rtest_t5 -19|Record should go to rtest_t5 and t7 +select * from rtest_t5; + a | b +----+------------------------------------- + 10 | Record should go to rtest_t5 + 15 | Record should go to rtest_t5 + 19 | Record should go to rtest_t5 and t7 (3 rows) -QUERY: select * from rtest_t6; - a|b ---+----------------------------------- -20|Record should go to rtest_t4 and t6 +select * from rtest_t6; + a | b +----+------------------------------------- + 20 | Record should go to rtest_t4 and t6 (1 row) -QUERY: select * from rtest_t7; - a|b ---+----------------------------------- -19|Record should go to rtest_t5 and t7 +select * from rtest_t7; + a | b +----+------------------------------------- + 19 | Record should go to rtest_t5 and t7 (1 row) -QUERY: select * from rtest_t8; - a|b ---+----------------------------------- -26|Record should go to rtest_t4 and t8 -28|Record should go to rtest_t4 and t8 +select * from rtest_t8; + a | b +----+------------------------------------- + 26 | Record should go to rtest_t4 and t8 + 28 | Record should go to rtest_t4 and t8 (2 rows) -QUERY: delete from rtest_t4; -QUERY: delete from rtest_t5; -QUERY: delete from rtest_t6; -QUERY: delete from rtest_t7; -QUERY: delete from rtest_t8; -QUERY: insert into rtest_t9 values (1, 'Record should go to rtest_t4'); -QUERY: insert into rtest_t9 values (2, 'Record should go to rtest_t4'); -QUERY: insert into rtest_t9 values (10, 'Record should go to rtest_t5'); -QUERY: insert into rtest_t9 values (15, 'Record should go to rtest_t5'); -QUERY: insert into rtest_t9 values (19, 'Record should go to rtest_t5 and t7'); -QUERY: insert into rtest_t9 values (20, 'Record should go to rtest_t4 and t6'); -QUERY: insert into rtest_t9 values (26, 'Record should go to rtest_t4 and t8'); -QUERY: insert into rtest_t9 values (28, 'Record should go to rtest_t4 and t8'); -QUERY: insert into rtest_t9 values (30, 'Record should go to rtest_t4'); -QUERY: insert into rtest_t9 values (40, 'Record should go to rtest_t4'); -QUERY: insert into rtest_t4 select * from rtest_t9 where a < 20; -QUERY: select * from rtest_t4; -a|b --+---------------------------- -1|Record should go to rtest_t4 -2|Record should go to rtest_t4 +delete from rtest_t4; +delete from rtest_t5; +delete from rtest_t6; +delete from rtest_t7; +delete from rtest_t8; +insert into rtest_t9 values (1, 'Record should go to rtest_t4'); +insert into rtest_t9 values (2, 'Record should go to rtest_t4'); +insert into rtest_t9 values (10, 'Record should go to rtest_t5'); +insert into rtest_t9 values (15, 'Record should go to rtest_t5'); +insert into rtest_t9 values (19, 'Record should go to rtest_t5 and t7'); +insert into rtest_t9 values (20, 'Record should go to rtest_t4 and t6'); +insert into rtest_t9 values (26, 'Record should go to rtest_t4 and t8'); +insert into rtest_t9 values (28, 'Record should go to rtest_t4 and t8'); +insert into rtest_t9 values (30, 'Record should go to rtest_t4'); +insert into rtest_t9 values (40, 'Record should go to rtest_t4'); +insert into rtest_t4 select * from rtest_t9 where a < 20; +select * from rtest_t4; + a | b +---+------------------------------ + 1 | Record should go to rtest_t4 + 2 | Record should go to rtest_t4 (2 rows) -QUERY: select * from rtest_t5; - a|b ---+----------------------------------- -10|Record should go to rtest_t5 -15|Record should go to rtest_t5 -19|Record should go to rtest_t5 and t7 +select * from rtest_t5; + a | b +----+------------------------------------- + 10 | Record should go to rtest_t5 + 15 | Record should go to rtest_t5 + 19 | Record should go to rtest_t5 and t7 (3 rows) -QUERY: select * from rtest_t6; -a|b --+- +select * from rtest_t6; + a | b +---+--- (0 rows) -QUERY: select * from rtest_t7; - a|b ---+----------------------------------- -19|Record should go to rtest_t5 and t7 +select * from rtest_t7; + a | b +----+------------------------------------- + 19 | Record should go to rtest_t5 and t7 (1 row) -QUERY: select * from rtest_t8; -a|b --+- +select * from rtest_t8; + a | b +---+--- (0 rows) -QUERY: insert into rtest_t4 select * from rtest_t9 where b ~ 'and t8'; -QUERY: select * from rtest_t4; - a|b ---+----------------------------------- - 1|Record should go to rtest_t4 - 2|Record should go to rtest_t4 -26|Record should go to rtest_t4 and t8 -28|Record should go to rtest_t4 and t8 +insert into rtest_t4 select * from rtest_t9 where b ~ 'and t8'; +select * from rtest_t4; + a | b +----+------------------------------------- + 1 | Record should go to rtest_t4 + 2 | Record should go to rtest_t4 + 26 | Record should go to rtest_t4 and t8 + 28 | Record should go to rtest_t4 and t8 (4 rows) -QUERY: select * from rtest_t5; - a|b ---+----------------------------------- -10|Record should go to rtest_t5 -15|Record should go to rtest_t5 -19|Record should go to rtest_t5 and t7 +select * from rtest_t5; + a | b +----+------------------------------------- + 10 | Record should go to rtest_t5 + 15 | Record should go to rtest_t5 + 19 | Record should go to rtest_t5 and t7 (3 rows) -QUERY: select * from rtest_t6; -a|b --+- +select * from rtest_t6; + a | b +---+--- (0 rows) -QUERY: select * from rtest_t7; - a|b ---+----------------------------------- -19|Record should go to rtest_t5 and t7 +select * from rtest_t7; + a | b +----+------------------------------------- + 19 | Record should go to rtest_t5 and t7 (1 row) -QUERY: select * from rtest_t8; - a|b ---+----------------------------------- -26|Record should go to rtest_t4 and t8 -28|Record should go to rtest_t4 and t8 +select * from rtest_t8; + a | b +----+------------------------------------- + 26 | Record should go to rtest_t4 and t8 + 28 | Record should go to rtest_t4 and t8 (2 rows) -QUERY: insert into rtest_t4 select a + 1, b from rtest_t9 where a in (20, 30, 40); -QUERY: select * from rtest_t4; - a|b ---+----------------------------------- - 1|Record should go to rtest_t4 - 2|Record should go to rtest_t4 -26|Record should go to rtest_t4 and t8 -28|Record should go to rtest_t4 and t8 -21|Record should go to rtest_t4 and t6 -31|Record should go to rtest_t4 -41|Record should go to rtest_t4 +insert into rtest_t4 select a + 1, b from rtest_t9 where a in (20, 30, 40); +select * from rtest_t4; + a | b +----+------------------------------------- + 1 | Record should go to rtest_t4 + 2 | Record should go to rtest_t4 + 26 | Record should go to rtest_t4 and t8 + 28 | Record should go to rtest_t4 and t8 + 21 | Record should go to rtest_t4 and t6 + 31 | Record should go to rtest_t4 + 41 | Record should go to rtest_t4 (7 rows) -QUERY: select * from rtest_t5; - a|b ---+----------------------------------- -10|Record should go to rtest_t5 -15|Record should go to rtest_t5 -19|Record should go to rtest_t5 and t7 +select * from rtest_t5; + a | b +----+------------------------------------- + 10 | Record should go to rtest_t5 + 15 | Record should go to rtest_t5 + 19 | Record should go to rtest_t5 and t7 (3 rows) -QUERY: select * from rtest_t6; - a|b ---+----------------------------------- -21|Record should go to rtest_t4 and t6 +select * from rtest_t6; + a | b +----+------------------------------------- + 21 | Record should go to rtest_t4 and t6 (1 row) -QUERY: select * from rtest_t7; - a|b ---+----------------------------------- -19|Record should go to rtest_t5 and t7 +select * from rtest_t7; + a | b +----+------------------------------------- + 19 | Record should go to rtest_t5 and t7 (1 row) -QUERY: select * from rtest_t8; - a|b ---+----------------------------------- -26|Record should go to rtest_t4 and t8 -28|Record should go to rtest_t4 and t8 +select * from rtest_t8; + a | b +----+------------------------------------- + 26 | Record should go to rtest_t4 and t8 + 28 | Record should go to rtest_t4 and t8 (2 rows) -QUERY: insert into rtest_order1 values (1); -QUERY: select * from rtest_order2; -a|b|c --+-+----------------------------------- -1|1|rule 2 - this should run 1st -1|2|rule 4 - this should run 2nd -1|3|rule 3 - this should run 3rd or 4th -1|4|rule 1 - this should run 3rd or 4th +-- +-- Check that the ordering of rules fired is correct +-- +insert into rtest_order1 values (1); +select * from rtest_order2; + a | b | c +---+---+------------------------------------- + 1 | 1 | rule 2 - this should run 1st + 1 | 2 | rule 4 - this should run 2nd + 1 | 3 | rule 3 - this should run 3rd or 4th + 1 | 4 | rule 1 - this should run 3rd or 4th (4 rows) -QUERY: insert into rtest_nothn1 values (1, 'want this'); -QUERY: insert into rtest_nothn1 values (2, 'want this'); -QUERY: insert into rtest_nothn1 values (10, 'don''t want this'); -QUERY: insert into rtest_nothn1 values (19, 'don''t want this'); -QUERY: insert into rtest_nothn1 values (20, 'want this'); -QUERY: insert into rtest_nothn1 values (29, 'want this'); -QUERY: insert into rtest_nothn1 values (30, 'don''t want this'); -QUERY: insert into rtest_nothn1 values (39, 'don''t want this'); -QUERY: insert into rtest_nothn1 values (40, 'want this'); -QUERY: insert into rtest_nothn1 values (50, 'want this'); -QUERY: insert into rtest_nothn1 values (60, 'want this'); -QUERY: select * from rtest_nothn1; - a|b ---+--------- - 1|want this - 2|want this -20|want this -29|want this -40|want this -50|want this -60|want this +-- +-- Check if instead nothing w/without qualification works +-- +insert into rtest_nothn1 values (1, 'want this'); +insert into rtest_nothn1 values (2, 'want this'); +insert into rtest_nothn1 values (10, 'don''t want this'); +insert into rtest_nothn1 values (19, 'don''t want this'); +insert into rtest_nothn1 values (20, 'want this'); +insert into rtest_nothn1 values (29, 'want this'); +insert into rtest_nothn1 values (30, 'don''t want this'); +insert into rtest_nothn1 values (39, 'don''t want this'); +insert into rtest_nothn1 values (40, 'want this'); +insert into rtest_nothn1 values (50, 'want this'); +insert into rtest_nothn1 values (60, 'want this'); +select * from rtest_nothn1; + a | b +----+----------- + 1 | want this + 2 | want this + 20 | want this + 29 | want this + 40 | want this + 50 | want this + 60 | want this (7 rows) -QUERY: insert into rtest_nothn2 values (10, 'too small'); -QUERY: insert into rtest_nothn2 values (50, 'too small'); -QUERY: insert into rtest_nothn2 values (100, 'OK'); -QUERY: insert into rtest_nothn2 values (200, 'OK'); -QUERY: select * from rtest_nothn2; -a|b --+- +insert into rtest_nothn2 values (10, 'too small'); +insert into rtest_nothn2 values (50, 'too small'); +insert into rtest_nothn2 values (100, 'OK'); +insert into rtest_nothn2 values (200, 'OK'); +select * from rtest_nothn2; + a | b +---+--- (0 rows) -QUERY: select * from rtest_nothn3; - a|b ----+-- -100|OK -200|OK +select * from rtest_nothn3; + a | b +-----+---- + 100 | OK + 200 | OK (2 rows) -QUERY: delete from rtest_nothn1; -QUERY: delete from rtest_nothn2; -QUERY: delete from rtest_nothn3; -QUERY: insert into rtest_nothn4 values (1, 'want this'); -QUERY: insert into rtest_nothn4 values (2, 'want this'); -QUERY: insert into rtest_nothn4 values (10, 'don''t want this'); -QUERY: insert into rtest_nothn4 values (19, 'don''t want this'); -QUERY: insert into rtest_nothn4 values (20, 'want this'); -QUERY: insert into rtest_nothn4 values (29, 'want this'); -QUERY: insert into rtest_nothn4 values (30, 'don''t want this'); -QUERY: insert into rtest_nothn4 values (39, 'don''t want this'); -QUERY: insert into rtest_nothn4 values (40, 'want this'); -QUERY: insert into rtest_nothn4 values (50, 'want this'); -QUERY: insert into rtest_nothn4 values (60, 'want this'); -QUERY: insert into rtest_nothn1 select * from rtest_nothn4; -QUERY: select * from rtest_nothn1; - a|b ---+--------- - 1|want this - 2|want this -20|want this -29|want this -40|want this -50|want this -60|want this +delete from rtest_nothn1; +delete from rtest_nothn2; +delete from rtest_nothn3; +insert into rtest_nothn4 values (1, 'want this'); +insert into rtest_nothn4 values (2, 'want this'); +insert into rtest_nothn4 values (10, 'don''t want this'); +insert into rtest_nothn4 values (19, 'don''t want this'); +insert into rtest_nothn4 values (20, 'want this'); +insert into rtest_nothn4 values (29, 'want this'); +insert into rtest_nothn4 values (30, 'don''t want this'); +insert into rtest_nothn4 values (39, 'don''t want this'); +insert into rtest_nothn4 values (40, 'want this'); +insert into rtest_nothn4 values (50, 'want this'); +insert into rtest_nothn4 values (60, 'want this'); +insert into rtest_nothn1 select * from rtest_nothn4; +select * from rtest_nothn1; + a | b +----+----------- + 1 | want this + 2 | want this + 20 | want this + 29 | want this + 40 | want this + 50 | want this + 60 | want this (7 rows) -QUERY: delete from rtest_nothn4; -QUERY: insert into rtest_nothn4 values (10, 'too small'); -QUERY: insert into rtest_nothn4 values (50, 'too small'); -QUERY: insert into rtest_nothn4 values (100, 'OK'); -QUERY: insert into rtest_nothn4 values (200, 'OK'); -QUERY: insert into rtest_nothn2 select * from rtest_nothn4; -QUERY: select * from rtest_nothn2; -a|b --+- +delete from rtest_nothn4; +insert into rtest_nothn4 values (10, 'too small'); +insert into rtest_nothn4 values (50, 'too small'); +insert into rtest_nothn4 values (100, 'OK'); +insert into rtest_nothn4 values (200, 'OK'); +insert into rtest_nothn2 select * from rtest_nothn4; +select * from rtest_nothn2; + a | b +---+--- (0 rows) -QUERY: select * from rtest_nothn3; - a|b ----+-- -100|OK -200|OK +select * from rtest_nothn3; + a | b +-----+---- + 100 | OK + 200 | OK (2 rows) -QUERY: create table rtest_view1 (a int4, b text, v bool); -QUERY: create table rtest_view2 (a int4); -QUERY: create table rtest_view3 (a int4, b text); -QUERY: create table rtest_view4 (a int4, b text, c int4); -QUERY: create view rtest_vview1 as select a, b from rtest_view1 X +create table rtest_view1 (a int4, b text, v bool); +create table rtest_view2 (a int4); +create table rtest_view3 (a int4, b text); +create table rtest_view4 (a int4, b text, c int4); +create view rtest_vview1 as select a, b from rtest_view1 X where 0 < (select count(*) from rtest_view2 Y where Y.a = X.a); -QUERY: create view rtest_vview2 as select a, b from rtest_view1 where v; -QUERY: create view rtest_vview3 as select a, b from rtest_vview2 X +create view rtest_vview2 as select a, b from rtest_view1 where v; +create view rtest_vview3 as select a, b from rtest_vview2 X where 0 < (select count(*) from rtest_view2 Y where Y.a = X.a); -QUERY: create view rtest_vview4 as select X.a, X.b, count(Y.a) as refcount +create view rtest_vview4 as select X.a, X.b, count(Y.a) as refcount from rtest_view1 X, rtest_view2 Y where X.a = Y.a group by X.a, X.b; -QUERY: create function rtest_viewfunc1(int4) returns int4 as +create function rtest_viewfunc1(int4) returns int4 as 'select count(*) from rtest_view2 where a = $1' language 'sql'; -QUERY: create view rtest_vview5 as select a, b, rtest_viewfunc1(a) as refcount +create view rtest_vview5 as select a, b, rtest_viewfunc1(a) as refcount from rtest_view1; -QUERY: insert into rtest_view1 values (1, 'item 1', 't'); -QUERY: insert into rtest_view1 values (2, 'item 2', 't'); -QUERY: insert into rtest_view1 values (3, 'item 3', 't'); -QUERY: insert into rtest_view1 values (4, 'item 4', 'f'); -QUERY: insert into rtest_view1 values (5, 'item 5', 't'); -QUERY: insert into rtest_view1 values (6, 'item 6', 'f'); -QUERY: insert into rtest_view1 values (7, 'item 7', 't'); -QUERY: insert into rtest_view1 values (8, 'item 8', 't'); -QUERY: insert into rtest_view2 values (2); -QUERY: insert into rtest_view2 values (2); -QUERY: insert into rtest_view2 values (4); -QUERY: insert into rtest_view2 values (5); -QUERY: insert into rtest_view2 values (7); -QUERY: insert into rtest_view2 values (7); -QUERY: insert into rtest_view2 values (7); -QUERY: insert into rtest_view2 values (7); -QUERY: select * from rtest_vview1; -a|b --+------ -2|item 2 -4|item 4 -5|item 5 -7|item 7 +insert into rtest_view1 values (1, 'item 1', 't'); +insert into rtest_view1 values (2, 'item 2', 't'); +insert into rtest_view1 values (3, 'item 3', 't'); +insert into rtest_view1 values (4, 'item 4', 'f'); +insert into rtest_view1 values (5, 'item 5', 't'); +insert into rtest_view1 values (6, 'item 6', 'f'); +insert into rtest_view1 values (7, 'item 7', 't'); +insert into rtest_view1 values (8, 'item 8', 't'); +insert into rtest_view2 values (2); +insert into rtest_view2 values (2); +insert into rtest_view2 values (4); +insert into rtest_view2 values (5); +insert into rtest_view2 values (7); +insert into rtest_view2 values (7); +insert into rtest_view2 values (7); +insert into rtest_view2 values (7); +select * from rtest_vview1; + a | b +---+-------- + 2 | item 2 + 4 | item 4 + 5 | item 5 + 7 | item 7 (4 rows) -QUERY: select * from rtest_vview2; -a|b --+------ -1|item 1 -2|item 2 -3|item 3 -5|item 5 -7|item 7 -8|item 8 +select * from rtest_vview2; + a | b +---+-------- + 1 | item 1 + 2 | item 2 + 3 | item 3 + 5 | item 5 + 7 | item 7 + 8 | item 8 (6 rows) -QUERY: select * from rtest_vview3; -a|b --+------ -2|item 2 -5|item 5 -7|item 7 +select * from rtest_vview3; + a | b +---+-------- + 2 | item 2 + 5 | item 5 + 7 | item 7 (3 rows) -QUERY: select * from rtest_vview4; -a|b |refcount --+------+-------- -2|item 2| 2 -4|item 4| 1 -5|item 5| 1 -7|item 7| 4 +select * from rtest_vview4; + a | b | refcount +---+--------+---------- + 2 | item 2 | 2 + 4 | item 4 | 1 + 5 | item 5 | 1 + 7 | item 7 | 4 (4 rows) -QUERY: select * from rtest_vview5; -a|b |refcount --+------+-------- -1|item 1| 0 -2|item 2| 2 -3|item 3| 0 -4|item 4| 1 -5|item 5| 1 -6|item 6| 0 -7|item 7| 4 -8|item 8| 0 +select * from rtest_vview5; + a | b | refcount +---+--------+---------- + 1 | item 1 | 0 + 2 | item 2 | 2 + 3 | item 3 | 0 + 4 | item 4 | 1 + 5 | item 5 | 1 + 6 | item 6 | 0 + 7 | item 7 | 4 + 8 | item 8 | 0 (8 rows) -QUERY: insert into rtest_view3 select * from rtest_vview1 where a < 7; -QUERY: select * from rtest_view3; -a|b --+------ -2|item 2 -4|item 4 -5|item 5 +insert into rtest_view3 select * from rtest_vview1 where a < 7; +select * from rtest_view3; + a | b +---+-------- + 2 | item 2 + 4 | item 4 + 5 | item 5 (3 rows) -QUERY: delete from rtest_view3; -QUERY: insert into rtest_view3 select * from rtest_vview2 where a != 5 and b !~ '2'; -QUERY: select * from rtest_view3; -a|b --+------ -1|item 1 -3|item 3 -7|item 7 -8|item 8 +delete from rtest_view3; +insert into rtest_view3 select * from rtest_vview2 where a != 5 and b !~ '2'; +select * from rtest_view3; + a | b +---+-------- + 1 | item 1 + 3 | item 3 + 7 | item 7 + 8 | item 8 (4 rows) -QUERY: delete from rtest_view3; -QUERY: insert into rtest_view3 select * from rtest_vview3; -QUERY: select * from rtest_view3; -a|b --+------ -2|item 2 -5|item 5 -7|item 7 +delete from rtest_view3; +insert into rtest_view3 select * from rtest_vview3; +select * from rtest_view3; + a | b +---+-------- + 2 | item 2 + 5 | item 5 + 7 | item 7 (3 rows) -QUERY: delete from rtest_view3; -QUERY: insert into rtest_view4 select * from rtest_vview4 where 3 > refcount; -QUERY: select * from rtest_view4; -a|b |c --+------+- -2|item 2|2 -4|item 4|1 -5|item 5|1 +delete from rtest_view3; +insert into rtest_view4 select * from rtest_vview4 where 3 > refcount; +select * from rtest_view4; + a | b | c +---+--------+--- + 2 | item 2 | 2 + 4 | item 4 | 1 + 5 | item 5 | 1 (3 rows) -QUERY: delete from rtest_view4; -QUERY: insert into rtest_view4 select * from rtest_vview5 where a > 2 and refcount = 0; -QUERY: select * from rtest_view4; -a|b |c --+------+- -3|item 3|0 -6|item 6|0 -8|item 8|0 +delete from rtest_view4; +insert into rtest_view4 select * from rtest_vview5 where a > 2 and refcount = 0; +select * from rtest_view4; + a | b | c +---+--------+--- + 3 | item 3 | 0 + 6 | item 6 | 0 + 8 | item 8 | 0 (3 rows) -QUERY: delete from rtest_view4; -QUERY: create table rtest_comp ( +delete from rtest_view4; +-- +-- Test for computations in views +-- +create table rtest_comp ( part text, unit char(4), size float ); -QUERY: create table rtest_unitfact ( +create table rtest_unitfact ( unit char(4), factor float ); -QUERY: create view rtest_vcomp as +create view rtest_vcomp as select X.part, (X.size * Y.factor) as size_in_cm from rtest_comp X, rtest_unitfact Y where X.unit = Y.unit; -QUERY: insert into rtest_unitfact values ('m', 100.0); -QUERY: insert into rtest_unitfact values ('cm', 1.0); -QUERY: insert into rtest_unitfact values ('inch', 2.54); -QUERY: insert into rtest_comp values ('p1', 'm', 5.0); -QUERY: insert into rtest_comp values ('p2', 'm', 3.0); -QUERY: insert into rtest_comp values ('p3', 'cm', 5.0); -QUERY: insert into rtest_comp values ('p4', 'cm', 15.0); -QUERY: insert into rtest_comp values ('p5', 'inch', 7.0); -QUERY: insert into rtest_comp values ('p6', 'inch', 4.4); -QUERY: select * from rtest_vcomp order by part; -part|size_in_cm -----+---------- -p1 | 500 -p2 | 300 -p3 | 5 -p4 | 15 -p5 | 17.78 -p6 | 11.176 +insert into rtest_unitfact values ('m', 100.0); +insert into rtest_unitfact values ('cm', 1.0); +insert into rtest_unitfact values ('inch', 2.54); +insert into rtest_comp values ('p1', 'm', 5.0); +insert into rtest_comp values ('p2', 'm', 3.0); +insert into rtest_comp values ('p3', 'cm', 5.0); +insert into rtest_comp values ('p4', 'cm', 15.0); +insert into rtest_comp values ('p5', 'inch', 7.0); +insert into rtest_comp values ('p6', 'inch', 4.4); +select * from rtest_vcomp order by part; + part | size_in_cm +------+------------ + p1 | 500 + p2 | 300 + p3 | 5 + p4 | 15 + p5 | 17.78 + p6 | 11.176 (6 rows) -QUERY: select * from rtest_vcomp where size_in_cm > 10.0 order by size_in_cm using >; -part|size_in_cm -----+---------- -p1 | 500 -p2 | 300 -p5 | 17.78 -p4 | 15 -p6 | 11.176 +select * from rtest_vcomp where size_in_cm > 10.0 order by size_in_cm using >; + part | size_in_cm +------+------------ + p1 | 500 + p2 | 300 + p5 | 17.78 + p4 | 15 + p6 | 11.176 (5 rows) -QUERY: CREATE TABLE shoe_data ( - shoename char(10), - sh_avail integer, - slcolor char(10), - slminlen float, - slmaxlen float, - slunit char(8) +-- +-- In addition run the (slightly modified) queries from the +-- programmers manual section on the rule system. +-- +CREATE TABLE shoe_data ( + shoename char(10), -- primary key + sh_avail integer, -- available # of pairs + slcolor char(10), -- preferred shoelace color + slminlen float, -- miminum shoelace length + slmaxlen float, -- maximum shoelace length + slunit char(8) -- length unit ); -QUERY: CREATE TABLE shoelace_data ( - sl_name char(10), - sl_avail integer, - sl_color char(10), - sl_len float, - sl_unit char(8) +CREATE TABLE shoelace_data ( + sl_name char(10), -- primary key + sl_avail integer, -- available # of pairs + sl_color char(10), -- shoelace color + sl_len float, -- shoelace length + sl_unit char(8) -- length unit ); -QUERY: CREATE TABLE unit ( - un_name char(8), - un_fact float +CREATE TABLE unit ( + un_name char(8), -- the primary key + un_fact float -- factor to transform to cm ); -QUERY: CREATE VIEW shoe AS +CREATE VIEW shoe AS SELECT sh.shoename, sh.sh_avail, sh.slcolor, @@ -879,7 +954,7 @@ QUERY: CREATE VIEW shoe AS sh.slunit FROM shoe_data sh, unit un WHERE sh.slunit = un.un_name; -QUERY: CREATE VIEW shoelace AS +CREATE VIEW shoelace AS SELECT s.sl_name, s.sl_avail, s.sl_color, @@ -888,7 +963,7 @@ QUERY: CREATE VIEW shoelace AS s.sl_len * u.un_fact AS sl_len_cm FROM shoelace_data s, unit u WHERE s.sl_unit = u.un_name; -QUERY: CREATE VIEW shoe_ready AS +CREATE VIEW shoe_ready AS SELECT rsh.shoename, rsh.sh_avail, rsl.sl_name, @@ -898,48 +973,52 @@ QUERY: CREATE VIEW shoe_ready AS WHERE rsl.sl_color = rsh.slcolor AND rsl.sl_len_cm >= rsh.slminlen_cm AND rsl.sl_len_cm <= rsh.slmaxlen_cm; -QUERY: INSERT INTO unit VALUES ('cm', 1.0); -QUERY: INSERT INTO unit VALUES ('m', 100.0); -QUERY: INSERT INTO unit VALUES ('inch', 2.54); -QUERY: INSERT INTO shoe_data VALUES ('sh1', 2, 'black', 70.0, 90.0, 'cm'); -QUERY: INSERT INTO shoe_data VALUES ('sh2', 0, 'black', 30.0, 40.0, 'inch'); -QUERY: INSERT INTO shoe_data VALUES ('sh3', 4, 'brown', 50.0, 65.0, 'cm'); -QUERY: INSERT INTO shoe_data VALUES ('sh4', 3, 'brown', 40.0, 50.0, 'inch'); -QUERY: INSERT INTO shoelace_data VALUES ('sl1', 5, 'black', 80.0, 'cm'); -QUERY: INSERT INTO shoelace_data VALUES ('sl2', 6, 'black', 100.0, 'cm'); -QUERY: INSERT INTO shoelace_data VALUES ('sl3', 0, 'black', 35.0 , 'inch'); -QUERY: INSERT INTO shoelace_data VALUES ('sl4', 8, 'black', 40.0 , 'inch'); -QUERY: INSERT INTO shoelace_data VALUES ('sl5', 4, 'brown', 1.0 , 'm'); -QUERY: INSERT INTO shoelace_data VALUES ('sl6', 0, 'brown', 0.9 , 'm'); -QUERY: INSERT INTO shoelace_data VALUES ('sl7', 7, 'brown', 60 , 'cm'); -QUERY: INSERT INTO shoelace_data VALUES ('sl8', 1, 'brown', 40 , 'inch'); -QUERY: SELECT * FROM shoelace ORDER BY sl_name; -sl_name |sl_avail|sl_color |sl_len|sl_unit |sl_len_cm -----------+--------+----------+------+--------+--------- -sl1 | 5|black | 80|cm | 80 -sl2 | 6|black | 100|cm | 100 -sl3 | 0|black | 35|inch | 88.9 -sl4 | 8|black | 40|inch | 101.6 -sl5 | 4|brown | 1|m | 100 -sl6 | 0|brown | 0.9|m | 90 -sl7 | 7|brown | 60|cm | 60 -sl8 | 1|brown | 40|inch | 101.6 +INSERT INTO unit VALUES ('cm', 1.0); +INSERT INTO unit VALUES ('m', 100.0); +INSERT INTO unit VALUES ('inch', 2.54); +INSERT INTO shoe_data VALUES ('sh1', 2, 'black', 70.0, 90.0, 'cm'); +INSERT INTO shoe_data VALUES ('sh2', 0, 'black', 30.0, 40.0, 'inch'); +INSERT INTO shoe_data VALUES ('sh3', 4, 'brown', 50.0, 65.0, 'cm'); +INSERT INTO shoe_data VALUES ('sh4', 3, 'brown', 40.0, 50.0, 'inch'); +INSERT INTO shoelace_data VALUES ('sl1', 5, 'black', 80.0, 'cm'); +INSERT INTO shoelace_data VALUES ('sl2', 6, 'black', 100.0, 'cm'); +INSERT INTO shoelace_data VALUES ('sl3', 0, 'black', 35.0 , 'inch'); +INSERT INTO shoelace_data VALUES ('sl4', 8, 'black', 40.0 , 'inch'); +INSERT INTO shoelace_data VALUES ('sl5', 4, 'brown', 1.0 , 'm'); +INSERT INTO shoelace_data VALUES ('sl6', 0, 'brown', 0.9 , 'm'); +INSERT INTO shoelace_data VALUES ('sl7', 7, 'brown', 60 , 'cm'); +INSERT INTO shoelace_data VALUES ('sl8', 1, 'brown', 40 , 'inch'); +-- SELECTs in doc +SELECT * FROM shoelace ORDER BY sl_name; + sl_name | sl_avail | sl_color | sl_len | sl_unit | sl_len_cm +------------+----------+------------+--------+----------+----------- + sl1 | 5 | black | 80 | cm | 80 + sl2 | 6 | black | 100 | cm | 100 + sl3 | 0 | black | 35 | inch | 88.9 + sl4 | 8 | black | 40 | inch | 101.6 + sl5 | 4 | brown | 1 | m | 100 + sl6 | 0 | brown | 0.9 | m | 90 + sl7 | 7 | brown | 60 | cm | 60 + sl8 | 1 | brown | 40 | inch | 101.6 (8 rows) -QUERY: SELECT * FROM shoe_ready WHERE total_avail >= 2; -shoename |sh_avail|sl_name |sl_avail|total_avail -----------+--------+----------+--------+----------- -sh1 | 2|sl1 | 5| 2 -sh3 | 4|sl7 | 7| 4 +SELECT * FROM shoe_ready WHERE total_avail >= 2; + shoename | sh_avail | sl_name | sl_avail | total_avail +------------+----------+------------+----------+------------- + sh1 | 2 | sl1 | 5 | 2 + sh3 | 4 | sl7 | 7 | 4 (2 rows) -QUERY: CREATE TABLE shoelace_log ( - sl_name char(10), - sl_avail integer, - log_who name, - log_when datetime + CREATE TABLE shoelace_log ( + sl_name char(10), -- shoelace changed + sl_avail integer, -- new available value + log_who name, -- who did it + log_when datetime -- when ); -QUERY: CREATE RULE log_shoelace AS ON UPDATE TO shoelace_data +-- Want "log_who" to be CURRENT_USER, +-- but that is non-portable for the regression test +-- - thomas 1999-02-21 + CREATE RULE log_shoelace AS ON UPDATE TO shoelace_data WHERE NEW.sl_avail != OLD.sl_avail DO INSERT INTO shoelace_log VALUES ( NEW.sl_name, @@ -947,14 +1026,14 @@ QUERY: CREATE RULE log_shoelace AS ON UPDATE TO shoelace_data 'Al Bundy', 'epoch'::text ); -QUERY: UPDATE shoelace_data SET sl_avail = 6 WHERE sl_name = 'sl7'; -QUERY: SELECT * FROM shoelace_log; -sl_name |sl_avail|log_who |log_when -----------+--------+--------+-------- -sl7 | 6|Al Bundy|epoch +UPDATE shoelace_data SET sl_avail = 6 WHERE sl_name = 'sl7'; +SELECT * FROM shoelace_log; + sl_name | sl_avail | log_who | log_when +------------+----------+----------+---------- + sl7 | 6 | Al Bundy | epoch (1 row) -QUERY: CREATE RULE shoelace_ins AS ON INSERT TO shoelace + CREATE RULE shoelace_ins AS ON INSERT TO shoelace DO INSTEAD INSERT INTO shoelace_data VALUES ( NEW.sl_name, @@ -962,7 +1041,7 @@ QUERY: CREATE RULE shoelace_ins AS ON INSERT TO shoelace NEW.sl_color, NEW.sl_len, NEW.sl_unit); -QUERY: CREATE RULE shoelace_upd AS ON UPDATE TO shoelace + CREATE RULE shoelace_upd AS ON UPDATE TO shoelace DO INSTEAD UPDATE shoelace_data SET sl_name = NEW.sl_name, @@ -971,154 +1050,157 @@ QUERY: CREATE RULE shoelace_upd AS ON UPDATE TO shoelace sl_len = NEW.sl_len, sl_unit = NEW.sl_unit WHERE sl_name = OLD.sl_name; -QUERY: CREATE RULE shoelace_del AS ON DELETE TO shoelace + CREATE RULE shoelace_del AS ON DELETE TO shoelace DO INSTEAD DELETE FROM shoelace_data WHERE sl_name = OLD.sl_name; -QUERY: CREATE TABLE shoelace_arrive ( + CREATE TABLE shoelace_arrive ( arr_name char(10), arr_quant integer ); -QUERY: CREATE TABLE shoelace_ok ( + CREATE TABLE shoelace_ok ( ok_name char(10), ok_quant integer ); -QUERY: CREATE RULE shoelace_ok_ins AS ON INSERT TO shoelace_ok + CREATE RULE shoelace_ok_ins AS ON INSERT TO shoelace_ok DO INSTEAD UPDATE shoelace SET sl_avail = sl_avail + NEW.ok_quant WHERE sl_name = NEW.ok_name; -QUERY: INSERT INTO shoelace_arrive VALUES ('sl3', 10); -QUERY: INSERT INTO shoelace_arrive VALUES ('sl6', 20); -QUERY: INSERT INTO shoelace_arrive VALUES ('sl8', 20); -QUERY: SELECT * FROM shoelace ORDER BY sl_name; -sl_name |sl_avail|sl_color |sl_len|sl_unit |sl_len_cm -----------+--------+----------+------+--------+--------- -sl1 | 5|black | 80|cm | 80 -sl2 | 6|black | 100|cm | 100 -sl3 | 0|black | 35|inch | 88.9 -sl4 | 8|black | 40|inch | 101.6 -sl5 | 4|brown | 1|m | 100 -sl6 | 0|brown | 0.9|m | 90 -sl7 | 6|brown | 60|cm | 60 -sl8 | 1|brown | 40|inch | 101.6 +INSERT INTO shoelace_arrive VALUES ('sl3', 10); +INSERT INTO shoelace_arrive VALUES ('sl6', 20); +INSERT INTO shoelace_arrive VALUES ('sl8', 20); +SELECT * FROM shoelace ORDER BY sl_name; + sl_name | sl_avail | sl_color | sl_len | sl_unit | sl_len_cm +------------+----------+------------+--------+----------+----------- + sl1 | 5 | black | 80 | cm | 80 + sl2 | 6 | black | 100 | cm | 100 + sl3 | 0 | black | 35 | inch | 88.9 + sl4 | 8 | black | 40 | inch | 101.6 + sl5 | 4 | brown | 1 | m | 100 + sl6 | 0 | brown | 0.9 | m | 90 + sl7 | 6 | brown | 60 | cm | 60 + sl8 | 1 | brown | 40 | inch | 101.6 (8 rows) -QUERY: insert into shoelace_ok select * from shoelace_arrive; -QUERY: SELECT * FROM shoelace ORDER BY sl_name; -sl_name |sl_avail|sl_color |sl_len|sl_unit |sl_len_cm -----------+--------+----------+------+--------+--------- -sl1 | 5|black | 80|cm | 80 -sl2 | 6|black | 100|cm | 100 -sl3 | 10|black | 35|inch | 88.9 -sl4 | 8|black | 40|inch | 101.6 -sl5 | 4|brown | 1|m | 100 -sl6 | 20|brown | 0.9|m | 90 -sl7 | 6|brown | 60|cm | 60 -sl8 | 21|brown | 40|inch | 101.6 +insert into shoelace_ok select * from shoelace_arrive; +SELECT * FROM shoelace ORDER BY sl_name; + sl_name | sl_avail | sl_color | sl_len | sl_unit | sl_len_cm +------------+----------+------------+--------+----------+----------- + sl1 | 5 | black | 80 | cm | 80 + sl2 | 6 | black | 100 | cm | 100 + sl3 | 10 | black | 35 | inch | 88.9 + sl4 | 8 | black | 40 | inch | 101.6 + sl5 | 4 | brown | 1 | m | 100 + sl6 | 20 | brown | 0.9 | m | 90 + sl7 | 6 | brown | 60 | cm | 60 + sl8 | 21 | brown | 40 | inch | 101.6 (8 rows) -QUERY: SELECT * FROM shoelace_log ORDER BY sl_name; -sl_name |sl_avail|log_who |log_when -----------+--------+--------+-------- -sl3 | 10|Al Bundy|epoch -sl6 | 20|Al Bundy|epoch -sl7 | 6|Al Bundy|epoch -sl8 | 21|Al Bundy|epoch +SELECT * FROM shoelace_log ORDER BY sl_name; + sl_name | sl_avail | log_who | log_when +------------+----------+----------+---------- + sl3 | 10 | Al Bundy | epoch + sl6 | 20 | Al Bundy | epoch + sl7 | 6 | Al Bundy | epoch + sl8 | 21 | Al Bundy | epoch (4 rows) -QUERY: CREATE VIEW shoelace_obsolete AS + CREATE VIEW shoelace_obsolete AS SELECT * FROM shoelace WHERE NOT EXISTS (SELECT shoename FROM shoe WHERE slcolor = sl_color); -QUERY: CREATE VIEW shoelace_candelete AS + CREATE VIEW shoelace_candelete AS SELECT * FROM shoelace_obsolete WHERE sl_avail = 0; -QUERY: insert into shoelace values ('sl9', 0, 'pink', 35.0, 'inch', 0.0); -QUERY: insert into shoelace values ('sl10', 1000, 'magenta', 40.0, 'inch', 0.0); -QUERY: SELECT * FROM shoelace_obsolete; -sl_name |sl_avail|sl_color |sl_len|sl_unit |sl_len_cm -----------+--------+----------+------+--------+--------- -sl9 | 0|pink | 35|inch | 88.9 -sl10 | 1000|magenta | 40|inch | 101.6 +insert into shoelace values ('sl9', 0, 'pink', 35.0, 'inch', 0.0); +insert into shoelace values ('sl10', 1000, 'magenta', 40.0, 'inch', 0.0); +SELECT * FROM shoelace_obsolete; + sl_name | sl_avail | sl_color | sl_len | sl_unit | sl_len_cm +------------+----------+------------+--------+----------+----------- + sl9 | 0 | pink | 35 | inch | 88.9 + sl10 | 1000 | magenta | 40 | inch | 101.6 (2 rows) -QUERY: SELECT * FROM shoelace_candelete; -sl_name |sl_avail|sl_color |sl_len|sl_unit |sl_len_cm -----------+--------+----------+------+--------+--------- -sl9 | 0|pink | 35|inch | 88.9 +SELECT * FROM shoelace_candelete; + sl_name | sl_avail | sl_color | sl_len | sl_unit | sl_len_cm +------------+----------+------------+--------+----------+----------- + sl9 | 0 | pink | 35 | inch | 88.9 (1 row) -QUERY: DELETE FROM shoelace WHERE EXISTS +DELETE FROM shoelace WHERE EXISTS (SELECT * FROM shoelace_candelete WHERE sl_name = shoelace.sl_name); -QUERY: SELECT * FROM shoelace ORDER BY sl_name; -sl_name |sl_avail|sl_color |sl_len|sl_unit |sl_len_cm -----------+--------+----------+------+--------+--------- -sl1 | 5|black | 80|cm | 80 -sl10 | 1000|magenta | 40|inch | 101.6 -sl2 | 6|black | 100|cm | 100 -sl3 | 10|black | 35|inch | 88.9 -sl4 | 8|black | 40|inch | 101.6 -sl5 | 4|brown | 1|m | 100 -sl6 | 20|brown | 0.9|m | 90 -sl7 | 6|brown | 60|cm | 60 -sl8 | 21|brown | 40|inch | 101.6 +SELECT * FROM shoelace ORDER BY sl_name; + sl_name | sl_avail | sl_color | sl_len | sl_unit | sl_len_cm +------------+----------+------------+--------+----------+----------- + sl1 | 5 | black | 80 | cm | 80 + sl10 | 1000 | magenta | 40 | inch | 101.6 + sl2 | 6 | black | 100 | cm | 100 + sl3 | 10 | black | 35 | inch | 88.9 + sl4 | 8 | black | 40 | inch | 101.6 + sl5 | 4 | brown | 1 | m | 100 + sl6 | 20 | brown | 0.9 | m | 90 + sl7 | 6 | brown | 60 | cm | 60 + sl8 | 21 | brown | 40 | inch | 101.6 (9 rows) -QUERY: SELECT viewname, definition FROM pg_views ORDER BY viewname; -viewname |definition -------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- -iexit |SELECT ih.name, ih.thepath, interpt_pp(ih.thepath, r.thepath) AS exit FROM ihighway ih, ramp r WHERE (ih.thepath ## r.thepath); -pg_indexes |SELECT c.relname AS tablename, i.relname AS indexname, pg_get_indexdef(x.indexrelid) AS indexdef FROM pg_index x, pg_class c, pg_class i WHERE ((c.oid = x.indrelid) AND (i.oid = x.indexrelid)); -pg_rules |SELECT c.relname AS tablename, r.rulename, pg_get_ruledef(r.rulename) AS definition FROM pg_rewrite r, pg_class c WHERE ((r.rulename !~ '^_RET'::text) AND (c.oid = r.ev_class)); -pg_tables |SELECT c.relname AS tablename, pg_get_userbyid(c.relowner) AS tableowner, c.relhasindex AS hasindexes, c.relhasrules AS hasrules, (c.reltriggers > 0) AS hastriggers FROM pg_class c WHERE (((c.relkind = 'r'::"char") OR (c.relkind = 's'::"char")) AND (NOT (EXISTS (SELECT pg_rewrite.rulename FROM pg_rewrite WHERE ((pg_rewrite.ev_class = c.oid) AND (pg_rewrite.ev_type = '1'::"char")))))); -pg_user |SELECT pg_shadow.usename, pg_shadow.usesysid, pg_shadow.usecreatedb, pg_shadow.usetrace, pg_shadow.usesuper, pg_shadow.usecatupd, '********'::text AS passwd, pg_shadow.valuntil FROM pg_shadow; -pg_views |SELECT c.relname AS viewname, pg_get_userbyid(c.relowner) AS viewowner, pg_get_viewdef(c.relname) AS definition FROM pg_class c WHERE (c.relhasrules AND (EXISTS (SELECT r.rulename FROM pg_rewrite r WHERE ((r.ev_class = c.oid) AND (r.ev_type = '1'::"char"))))); -rtest_v1 |SELECT rtest_t1.a, rtest_t1.b FROM rtest_t1; -rtest_vcomp |SELECT x.part, (x.size * y.factor) AS size_in_cm FROM rtest_comp x, rtest_unitfact y WHERE (x.unit = y.unit); -rtest_vview1 |SELECT x.a, x.b FROM rtest_view1 x WHERE (0 < (SELECT count(*) AS count FROM rtest_view2 y WHERE (y.a = x.a))); -rtest_vview2 |SELECT rtest_view1.a, rtest_view1.b FROM rtest_view1 WHERE rtest_view1.v; -rtest_vview3 |SELECT x.a, x.b FROM rtest_vview2 x WHERE (0 < (SELECT count(*) AS count FROM rtest_view2 y WHERE (y.a = x.a))); -rtest_vview4 |SELECT x.a, x.b, count(y.a) AS refcount FROM rtest_view1 x, rtest_view2 y WHERE (x.a = y.a) GROUP BY x.a, x.b; -rtest_vview5 |SELECT rtest_view1.a, rtest_view1.b, rtest_viewfunc1(rtest_view1.a) AS refcount FROM rtest_view1; -shoe |SELECT sh.shoename, sh.sh_avail, sh.slcolor, sh.slminlen, (sh.slminlen * un.un_fact) AS slminlen_cm, sh.slmaxlen, (sh.slmaxlen * un.un_fact) AS slmaxlen_cm, sh.slunit FROM shoe_data sh, unit un WHERE (sh.slunit = un.un_name); -shoe_ready |SELECT rsh.shoename, rsh.sh_avail, rsl.sl_name, rsl.sl_avail, int4smaller(rsh.sh_avail, rsl.sl_avail) AS total_avail FROM shoe rsh, shoelace rsl WHERE (((rsl.sl_color = rsh.slcolor) AND (rsl.sl_len_cm >= rsh.slminlen_cm)) AND (rsl.sl_len_cm <= rsh.slmaxlen_cm)); -shoelace |SELECT s.sl_name, s.sl_avail, s.sl_color, s.sl_len, s.sl_unit, (s.sl_len * u.un_fact) AS sl_len_cm FROM shoelace_data s, unit u WHERE (s.sl_unit = u.un_name); -shoelace_candelete|SELECT shoelace_obsolete.sl_name, shoelace_obsolete.sl_avail, shoelace_obsolete.sl_color, shoelace_obsolete.sl_len, shoelace_obsolete.sl_unit, shoelace_obsolete.sl_len_cm FROM shoelace_obsolete WHERE (shoelace_obsolete.sl_avail = 0); -shoelace_obsolete |SELECT shoelace.sl_name, shoelace.sl_avail, shoelace.sl_color, shoelace.sl_len, shoelace.sl_unit, shoelace.sl_len_cm FROM shoelace WHERE (NOT (EXISTS (SELECT shoe.shoename FROM shoe WHERE (shoe.slcolor = shoelace.sl_color)))); -street |SELECT r.name, r.thepath, c.cname FROM road r, real_city c WHERE (c.outline ## r.thepath); -toyemp |SELECT emp.name, emp.age, emp."location", (12 * emp.salary) AS annualsal FROM emp; +-- +-- Check that ruleutils are working +-- +SELECT viewname, definition FROM pg_views ORDER BY viewname; + viewname | definition +--------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- + iexit | SELECT ih.name, ih.thepath, interpt_pp(ih.thepath, r.thepath) AS exit FROM ihighway ih, ramp r WHERE (ih.thepath ## r.thepath); + pg_indexes | SELECT c.relname AS tablename, i.relname AS indexname, pg_get_indexdef(x.indexrelid) AS indexdef FROM pg_index x, pg_class c, pg_class i WHERE ((c.oid = x.indrelid) AND (i.oid = x.indexrelid)); + pg_rules | SELECT c.relname AS tablename, r.rulename, pg_get_ruledef(r.rulename) AS definition FROM pg_rewrite r, pg_class c WHERE ((r.rulename !~ '^_RET'::text) AND (c.oid = r.ev_class)); + pg_tables | SELECT c.relname AS tablename, pg_get_userbyid(c.relowner) AS tableowner, c.relhasindex AS hasindexes, c.relhasrules AS hasrules, (c.reltriggers > 0) AS hastriggers FROM pg_class c WHERE (((c.relkind = 'r'::"char") OR (c.relkind = 's'::"char")) AND (NOT (EXISTS (SELECT pg_rewrite.rulename FROM pg_rewrite WHERE ((pg_rewrite.ev_class = c.oid) AND (pg_rewrite.ev_type = '1'::"char")))))); + pg_user | SELECT pg_shadow.usename, pg_shadow.usesysid, pg_shadow.usecreatedb, pg_shadow.usetrace, pg_shadow.usesuper, pg_shadow.usecatupd, '********'::text AS passwd, pg_shadow.valuntil FROM pg_shadow; + pg_views | SELECT c.relname AS viewname, pg_get_userbyid(c.relowner) AS viewowner, pg_get_viewdef(c.relname) AS definition FROM pg_class c WHERE (c.relhasrules AND (EXISTS (SELECT r.rulename FROM pg_rewrite r WHERE ((r.ev_class = c.oid) AND (r.ev_type = '1'::"char"))))); + rtest_v1 | SELECT rtest_t1.a, rtest_t1.b FROM rtest_t1; + rtest_vcomp | SELECT x.part, (x.size * y.factor) AS size_in_cm FROM rtest_comp x, rtest_unitfact y WHERE (x.unit = y.unit); + rtest_vview1 | SELECT x.a, x.b FROM rtest_view1 x WHERE (0 < (SELECT count(*) AS count FROM rtest_view2 y WHERE (y.a = x.a))); + rtest_vview2 | SELECT rtest_view1.a, rtest_view1.b FROM rtest_view1 WHERE rtest_view1.v; + rtest_vview3 | SELECT x.a, x.b FROM rtest_vview2 x WHERE (0 < (SELECT count(*) AS count FROM rtest_view2 y WHERE (y.a = x.a))); + rtest_vview4 | SELECT x.a, x.b, count(y.a) AS refcount FROM rtest_view1 x, rtest_view2 y WHERE (x.a = y.a) GROUP BY x.a, x.b; + rtest_vview5 | SELECT rtest_view1.a, rtest_view1.b, rtest_viewfunc1(rtest_view1.a) AS refcount FROM rtest_view1; + shoe | SELECT sh.shoename, sh.sh_avail, sh.slcolor, sh.slminlen, (sh.slminlen * un.un_fact) AS slminlen_cm, sh.slmaxlen, (sh.slmaxlen * un.un_fact) AS slmaxlen_cm, sh.slunit FROM shoe_data sh, unit un WHERE (sh.slunit = un.un_name); + shoe_ready | SELECT rsh.shoename, rsh.sh_avail, rsl.sl_name, rsl.sl_avail, int4smaller(rsh.sh_avail, rsl.sl_avail) AS total_avail FROM shoe rsh, shoelace rsl WHERE (((rsl.sl_color = rsh.slcolor) AND (rsl.sl_len_cm >= rsh.slminlen_cm)) AND (rsl.sl_len_cm <= rsh.slmaxlen_cm)); + shoelace | SELECT s.sl_name, s.sl_avail, s.sl_color, s.sl_len, s.sl_unit, (s.sl_len * u.un_fact) AS sl_len_cm FROM shoelace_data s, unit u WHERE (s.sl_unit = u.un_name); + shoelace_candelete | SELECT shoelace_obsolete.sl_name, shoelace_obsolete.sl_avail, shoelace_obsolete.sl_color, shoelace_obsolete.sl_len, shoelace_obsolete.sl_unit, shoelace_obsolete.sl_len_cm FROM shoelace_obsolete WHERE (shoelace_obsolete.sl_avail = 0); + shoelace_obsolete | SELECT shoelace.sl_name, shoelace.sl_avail, shoelace.sl_color, shoelace.sl_len, shoelace.sl_unit, shoelace.sl_len_cm FROM shoelace WHERE (NOT (EXISTS (SELECT shoe.shoename FROM shoe WHERE (shoe.slcolor = shoelace.sl_color)))); + street | SELECT r.name, r.thepath, c.cname FROM road r, real_city c WHERE (c.outline ## r.thepath); + toyemp | SELECT emp.name, emp.age, emp."location", (12 * emp.salary) AS annualsal FROM emp; (20 rows) -QUERY: SELECT tablename, rulename, definition FROM pg_rules +SELECT tablename, rulename, definition FROM pg_rules ORDER BY tablename, rulename; -tablename |rulename |definition --------------+---------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ -rtest_emp |rtest_emp_del |CREATE RULE rtest_emp_del AS ON DELETE TO rtest_emp DO INSERT INTO rtest_emplog (ename, who, "action", newsal, oldsal) VALUES (old.ename, getpgusername(), 'fired'::bpchar, '$0.00'::money, old.salary); -rtest_emp |rtest_emp_ins |CREATE RULE rtest_emp_ins AS ON INSERT TO rtest_emp DO INSERT INTO rtest_emplog (ename, who, "action", newsal, oldsal) VALUES (new.ename, getpgusername(), 'hired'::bpchar, new.salary, '$0.00'::money); -rtest_emp |rtest_emp_upd |CREATE RULE rtest_emp_upd AS ON UPDATE TO rtest_emp WHERE (new.salary <> old.salary) DO INSERT INTO rtest_emplog (ename, who, "action", newsal, oldsal) VALUES (new.ename, getpgusername(), 'honored'::bpchar, new.salary, old.salary); -rtest_nothn1 |rtest_nothn_r1 |CREATE RULE rtest_nothn_r1 AS ON INSERT TO rtest_nothn1 WHERE ((new.a >= 10) AND (new.a < 20)) DO INSTEAD SELECT 1; -rtest_nothn1 |rtest_nothn_r2 |CREATE RULE rtest_nothn_r2 AS ON INSERT TO rtest_nothn1 WHERE ((new.a >= 30) AND (new.a < 40)) DO INSTEAD NOTHING; -rtest_nothn2 |rtest_nothn_r3 |CREATE RULE rtest_nothn_r3 AS ON INSERT TO rtest_nothn2 WHERE (new.a >= 100) DO INSTEAD INSERT INTO rtest_nothn3 (a, b) VALUES (new.a, new.b); -rtest_nothn2 |rtest_nothn_r4 |CREATE RULE rtest_nothn_r4 AS ON INSERT TO rtest_nothn2 DO INSTEAD NOTHING; -rtest_order1 |rtest_order_r1 |CREATE RULE rtest_order_r1 AS ON INSERT TO rtest_order1 DO INSTEAD INSERT INTO rtest_order2 (a, b, c) VALUES (new.a, nextval('rtest_seq'::text), 'rule 1 - this should run 3rd or 4th'::text); -rtest_order1 |rtest_order_r2 |CREATE RULE rtest_order_r2 AS ON INSERT TO rtest_order1 DO INSERT INTO rtest_order2 (a, b, c) VALUES (new.a, nextval('rtest_seq'::text), 'rule 2 - this should run 1st'::text); -rtest_order1 |rtest_order_r3 |CREATE RULE rtest_order_r3 AS ON INSERT TO rtest_order1 DO INSTEAD INSERT INTO rtest_order2 (a, b, c) VALUES (new.a, nextval('rtest_seq'::text), 'rule 3 - this should run 3rd or 4th'::text); -rtest_order1 |rtest_order_r4 |CREATE RULE rtest_order_r4 AS ON INSERT TO rtest_order1 WHERE (rtest_order2.a < 100) DO INSTEAD INSERT INTO rtest_order2 (a, b, c) VALUES (new.a, nextval('rtest_seq'::text), 'rule 4 - this should run 2nd'::text); -rtest_person |rtest_pers_del |CREATE RULE rtest_pers_del AS ON DELETE TO rtest_person DO DELETE FROM rtest_admin WHERE (rtest_admin.pname = old.pname); -rtest_person |rtest_pers_upd |CREATE RULE rtest_pers_upd AS ON UPDATE TO rtest_person DO UPDATE rtest_admin SET pname = new.pname WHERE (rtest_admin.pname = old.pname); -rtest_system |rtest_sys_del |CREATE RULE rtest_sys_del AS ON DELETE TO rtest_system DO (DELETE FROM rtest_interface WHERE (rtest_interface.sysname = old.sysname); DELETE FROM rtest_admin WHERE (rtest_admin.sysname = old.sysname); ); -rtest_system |rtest_sys_upd |CREATE RULE rtest_sys_upd AS ON UPDATE TO rtest_system DO (UPDATE rtest_interface SET sysname = new.sysname WHERE (rtest_interface.sysname = old.sysname); UPDATE rtest_admin SET sysname = new.sysname WHERE (rtest_admin.sysname = old.sysname); ); -rtest_t4 |rtest_t4_ins1 |CREATE RULE rtest_t4_ins1 AS ON INSERT TO rtest_t4 WHERE ((new.a >= 10) AND (new.a < 20)) DO INSTEAD INSERT INTO rtest_t5 (a, b) VALUES (new.a, new.b); -rtest_t4 |rtest_t4_ins2 |CREATE RULE rtest_t4_ins2 AS ON INSERT TO rtest_t4 WHERE ((new.a >= 20) AND (new.a < 30)) DO INSERT INTO rtest_t6 (a, b) VALUES (new.a, new.b); -rtest_t5 |rtest_t5_ins |CREATE RULE rtest_t5_ins AS ON INSERT TO rtest_t5 WHERE (new.a > 15) DO INSERT INTO rtest_t7 (a, b) VALUES (new.a, new.b); -rtest_t6 |rtest_t6_ins |CREATE RULE rtest_t6_ins AS ON INSERT TO rtest_t6 WHERE (new.a > 25) DO INSTEAD INSERT INTO rtest_t8 (a, b) VALUES (new.a, new.b); -rtest_v1 |rtest_v1_del |CREATE RULE rtest_v1_del AS ON DELETE TO rtest_v1 DO INSTEAD DELETE FROM rtest_t1 WHERE (rtest_t1.a = old.a); -rtest_v1 |rtest_v1_ins |CREATE RULE rtest_v1_ins AS ON INSERT TO rtest_v1 DO INSTEAD INSERT INTO rtest_t1 (a, b) VALUES (new.a, new.b); -rtest_v1 |rtest_v1_upd |CREATE RULE rtest_v1_upd AS ON UPDATE TO rtest_v1 DO INSTEAD UPDATE rtest_t1 SET a = new.a, b = new.b WHERE (rtest_t1.a = old.a); -shoelace |shoelace_del |CREATE RULE shoelace_del AS ON DELETE TO shoelace DO INSTEAD DELETE FROM shoelace_data WHERE (shoelace_data.sl_name = old.sl_name); -shoelace |shoelace_ins |CREATE RULE shoelace_ins AS ON INSERT TO shoelace DO INSTEAD INSERT INTO shoelace_data (sl_name, sl_avail, sl_color, sl_len, sl_unit) VALUES (new.sl_name, new.sl_avail, new.sl_color, new.sl_len, new.sl_unit); -shoelace |shoelace_upd |CREATE RULE shoelace_upd AS ON UPDATE TO shoelace DO INSTEAD UPDATE shoelace_data SET sl_name = new.sl_name, sl_avail = new.sl_avail, sl_color = new.sl_color, sl_len = new.sl_len, sl_unit = new.sl_unit WHERE (shoelace_data.sl_name = old.sl_name); -shoelace_data|log_shoelace |CREATE RULE log_shoelace AS ON UPDATE TO shoelace_data WHERE (new.sl_avail <> old.sl_avail) DO INSERT INTO shoelace_log (sl_name, sl_avail, log_who, log_when) VALUES (new.sl_name, new.sl_avail, 'Al Bundy'::name, datetime('epoch'::text)); -shoelace_ok |shoelace_ok_ins|CREATE RULE shoelace_ok_ins AS ON INSERT TO shoelace_ok DO INSTEAD UPDATE shoelace SET sl_avail = (shoelace.sl_avail + new.ok_quant) WHERE (shoelace.sl_name = new.ok_name); + tablename | rulename | definition +---------------+-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- + rtest_emp | rtest_emp_del | CREATE RULE rtest_emp_del AS ON DELETE TO rtest_emp DO INSERT INTO rtest_emplog (ename, who, "action", newsal, oldsal) VALUES (old.ename, getpgusername(), 'fired'::bpchar, '$0.00'::money, old.salary); + rtest_emp | rtest_emp_ins | CREATE RULE rtest_emp_ins AS ON INSERT TO rtest_emp DO INSERT INTO rtest_emplog (ename, who, "action", newsal, oldsal) VALUES (new.ename, getpgusername(), 'hired'::bpchar, new.salary, '$0.00'::money); + rtest_emp | rtest_emp_upd | CREATE RULE rtest_emp_upd AS ON UPDATE TO rtest_emp WHERE (new.salary <> old.salary) DO INSERT INTO rtest_emplog (ename, who, "action", newsal, oldsal) VALUES (new.ename, getpgusername(), 'honored'::bpchar, new.salary, old.salary); + rtest_nothn1 | rtest_nothn_r1 | CREATE RULE rtest_nothn_r1 AS ON INSERT TO rtest_nothn1 WHERE ((new.a >= 10) AND (new.a < 20)) DO INSTEAD SELECT 1; + rtest_nothn1 | rtest_nothn_r2 | CREATE RULE rtest_nothn_r2 AS ON INSERT TO rtest_nothn1 WHERE ((new.a >= 30) AND (new.a < 40)) DO INSTEAD NOTHING; + rtest_nothn2 | rtest_nothn_r3 | CREATE RULE rtest_nothn_r3 AS ON INSERT TO rtest_nothn2 WHERE (new.a >= 100) DO INSTEAD INSERT INTO rtest_nothn3 (a, b) VALUES (new.a, new.b); + rtest_nothn2 | rtest_nothn_r4 | CREATE RULE rtest_nothn_r4 AS ON INSERT TO rtest_nothn2 DO INSTEAD NOTHING; + rtest_order1 | rtest_order_r1 | CREATE RULE rtest_order_r1 AS ON INSERT TO rtest_order1 DO INSTEAD INSERT INTO rtest_order2 (a, b, c) VALUES (new.a, nextval('rtest_seq'::text), 'rule 1 - this should run 3rd or 4th'::text); + rtest_order1 | rtest_order_r2 | CREATE RULE rtest_order_r2 AS ON INSERT TO rtest_order1 DO INSERT INTO rtest_order2 (a, b, c) VALUES (new.a, nextval('rtest_seq'::text), 'rule 2 - this should run 1st'::text); + rtest_order1 | rtest_order_r3 | CREATE RULE rtest_order_r3 AS ON INSERT TO rtest_order1 DO INSTEAD INSERT INTO rtest_order2 (a, b, c) VALUES (new.a, nextval('rtest_seq'::text), 'rule 3 - this should run 3rd or 4th'::text); + rtest_order1 | rtest_order_r4 | CREATE RULE rtest_order_r4 AS ON INSERT TO rtest_order1 WHERE (rtest_order2.a < 100) DO INSTEAD INSERT INTO rtest_order2 (a, b, c) VALUES (new.a, nextval('rtest_seq'::text), 'rule 4 - this should run 2nd'::text); + rtest_person | rtest_pers_del | CREATE RULE rtest_pers_del AS ON DELETE TO rtest_person DO DELETE FROM rtest_admin WHERE (rtest_admin.pname = old.pname); + rtest_person | rtest_pers_upd | CREATE RULE rtest_pers_upd AS ON UPDATE TO rtest_person DO UPDATE rtest_admin SET pname = new.pname WHERE (rtest_admin.pname = old.pname); + rtest_system | rtest_sys_del | CREATE RULE rtest_sys_del AS ON DELETE TO rtest_system DO (DELETE FROM rtest_interface WHERE (rtest_interface.sysname = old.sysname); DELETE FROM rtest_admin WHERE (rtest_admin.sysname = old.sysname); ); + rtest_system | rtest_sys_upd | CREATE RULE rtest_sys_upd AS ON UPDATE TO rtest_system DO (UPDATE rtest_interface SET sysname = new.sysname WHERE (rtest_interface.sysname = old.sysname); UPDATE rtest_admin SET sysname = new.sysname WHERE (rtest_admin.sysname = old.sysname); ); + rtest_t4 | rtest_t4_ins1 | CREATE RULE rtest_t4_ins1 AS ON INSERT TO rtest_t4 WHERE ((new.a >= 10) AND (new.a < 20)) DO INSTEAD INSERT INTO rtest_t5 (a, b) VALUES (new.a, new.b); + rtest_t4 | rtest_t4_ins2 | CREATE RULE rtest_t4_ins2 AS ON INSERT TO rtest_t4 WHERE ((new.a >= 20) AND (new.a < 30)) DO INSERT INTO rtest_t6 (a, b) VALUES (new.a, new.b); + rtest_t5 | rtest_t5_ins | CREATE RULE rtest_t5_ins AS ON INSERT TO rtest_t5 WHERE (new.a > 15) DO INSERT INTO rtest_t7 (a, b) VALUES (new.a, new.b); + rtest_t6 | rtest_t6_ins | CREATE RULE rtest_t6_ins AS ON INSERT TO rtest_t6 WHERE (new.a > 25) DO INSTEAD INSERT INTO rtest_t8 (a, b) VALUES (new.a, new.b); + rtest_v1 | rtest_v1_del | CREATE RULE rtest_v1_del AS ON DELETE TO rtest_v1 DO INSTEAD DELETE FROM rtest_t1 WHERE (rtest_t1.a = old.a); + rtest_v1 | rtest_v1_ins | CREATE RULE rtest_v1_ins AS ON INSERT TO rtest_v1 DO INSTEAD INSERT INTO rtest_t1 (a, b) VALUES (new.a, new.b); + rtest_v1 | rtest_v1_upd | CREATE RULE rtest_v1_upd AS ON UPDATE TO rtest_v1 DO INSTEAD UPDATE rtest_t1 SET a = new.a, b = new.b WHERE (rtest_t1.a = old.a); + shoelace | shoelace_del | CREATE RULE shoelace_del AS ON DELETE TO shoelace DO INSTEAD DELETE FROM shoelace_data WHERE (shoelace_data.sl_name = old.sl_name); + shoelace | shoelace_ins | CREATE RULE shoelace_ins AS ON INSERT TO shoelace DO INSTEAD INSERT INTO shoelace_data (sl_name, sl_avail, sl_color, sl_len, sl_unit) VALUES (new.sl_name, new.sl_avail, new.sl_color, new.sl_len, new.sl_unit); + shoelace | shoelace_upd | CREATE RULE shoelace_upd AS ON UPDATE TO shoelace DO INSTEAD UPDATE shoelace_data SET sl_name = new.sl_name, sl_avail = new.sl_avail, sl_color = new.sl_color, sl_len = new.sl_len, sl_unit = new.sl_unit WHERE (shoelace_data.sl_name = old.sl_name); + shoelace_data | log_shoelace | CREATE RULE log_shoelace AS ON UPDATE TO shoelace_data WHERE (new.sl_avail <> old.sl_avail) DO INSERT INTO shoelace_log (sl_name, sl_avail, log_who, log_when) VALUES (new.sl_name, new.sl_avail, 'Al Bundy'::name, datetime('epoch'::text)); + shoelace_ok | shoelace_ok_ins | CREATE RULE shoelace_ok_ins AS ON INSERT TO shoelace_ok DO INSTEAD UPDATE shoelace SET sl_avail = (shoelace.sl_avail + new.ok_quant) WHERE (shoelace.sl_name = new.ok_name); (27 rows) diff --git a/src/test/regress/expected/select_views.out b/src/test/regress/expected/select_views.out index 82a804e8ab..fcb5c76c0e 100644 --- a/src/test/regress/expected/select_views.out +++ b/src/test/regress/expected/select_views.out @@ -1,1192 +1,1196 @@ -QUERY: SELECT * FROM street; -name |thepath |cname -----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------- -Access Rd 25 |[(-121.9283,37.894),(-121.9283,37.9)] |Oakland -Agua Fria Creek |[(-121.9254,37.922),(-121.9281,37.889)] |Oakland -Andrea Cir |[(-121.733218,37.88641),(-121.733286,37.90617)] |Oakland -Apricot Lane|[(-121.9471,37.401),(-121.9456,37.392)] |Oakland -Arlington Dr |[(-121.8802,37.408),(-121.8807,37.394)] |Oakland -Arlington Road|[(-121.7957,37.898),(-121.7956,37.906)] |Oakland -Arroyo Las Positas |[(-121.7973,37.997),(-121.7957,37.005)] |Oakland -Arroyo Seco |[(-121.7073,37.766),(-121.6997,37.729)] |Oakland -Calaveras Creek |[(-121.8203,37.035),(-121.8207,37.931)] |Oakland -Corriea Way |[(-121.9501,37.402),(-121.9505,37.398)] |Oakland -Cowing Road|[(-122.0002,37.934),(-121.9772,37.782)] |Oakland -Driscoll Road|[(-121.9482,37.403),(-121.948451,37.39995)] |Oakland -Enos Way |[(-121.7677,37.896),(-121.7673,37.91)] |Oakland -Fairview Ave |[(-121.999,37.428),(-121.9863,37.351)] |Oakland -I- 580 |[(-121.9322,37.989),(-121.9243,37.006),(-121.9217,37.014)] |Oakland -I- 580 |[(-122.018,37.019),(-122.0009,37.032),(-121.9787,37.983),(-121.958,37.984),(-121.9571,37.986)] |Oakland -I- 580 Ramp|[(-121.8521,37.011),(-121.8479,37.999),(-121.8476,37.999),(-121.8456,37.01),(-121.8455,37.011)] |Oakland -I- 580 Ramp|[(-121.8743,37.014),(-121.8722,37.999),(-121.8714,37.999)] |Oakland -I- 580 Ramp|[(-121.9043,37.998),(-121.9036,37.013),(-121.902632,37.0174),(-121.9025,37.018)] |Oakland -I- 580 Ramp|[(-121.9368,37.986),(-121.936483,37.98832),(-121.9353,37.997),(-121.93504,37.00035),(-121.9346,37.006),(-121.933764,37.00031),(-121.9333,37.997),(-121.9322,37.989)] |Oakland -I- 580/I-680 Ramp|((-121.9207,37.988),(-121.9192,37.016)) |Oakland -I- 680 |((-121.939,37.15),(-121.9387,37.145),(-121.9373,37.125),(-121.934242,37.07643),(-121.933886,37.0709),(-121.9337,37.068),(-121.933122,37.06139),(-121.932736,37.05698),(-121.93222,37.05108),(-121.931844,37.04678),(-121.930113,37.027),(-121.926829,37),(-121.9265,37.998),(-121.9217,37.96),(-121.9203,37.949),(-121.9184,37.934)) |Oakland -I- 680 |[(-121.9101,37.715),(-121.911269,37.74682),(-121.9119,37.764),(-121.9124,37.776),(-121.9174,37.905),(-121.9194,37.957),(-121.9207,37.988)] |Oakland -I- 680 |[(-121.9184,37.934),(-121.917,37.913),(-121.9122,37.83),(-121.9052,37.702)] |Oakland -I- 680 Ramp|[(-121.8833,37.376),(-121.8833,37.392),(-121.883,37.4),(-121.8835,37.402),(-121.8852,37.422)] |Oakland -I- 680 Ramp|[(-121.92,37.438),(-121.9218,37.424),(-121.9238,37.408),(-121.9252,37.392)] |Oakland -I- 680 Ramp|[(-121.9238,37.402),(-121.9234,37.395),(-121.923,37.399)] |Oakland -I- 880 |((-121.9669,37.075),(-121.9663,37.071),(-121.9656,37.065),(-121.9618,37.037),(-121.95689,37),(-121.948,37.933)) |Oakland -I- 880 |[(-121.948,37.933),(-121.9471,37.925),(-121.9467,37.923),(-121.946,37.918),(-121.9452,37.912),(-121.937,37.852)] |Oakland -Johnson Dr |[(-121.9145,37.901),(-121.915,37.877)] |Oakland -Juniper St |[(-121.7823,37.897),(-121.7815,37.9)] |Oakland -Las Positas Road|[(-121.764488,37.99199),(-121.75569,37.02022)] |Oakland -Livermore Ave |[(-121.7687,37.448),(-121.769,37.375)] |Oakland -Livermore Ave |[(-121.772719,37.99085),(-121.7728,37.001)] |Oakland -Mission Blvd|[(-121.918886,37),(-121.9194,37.976),(-121.9198,37.975)] |Oakland -Navajo Ct |[(-121.8779,37.901),(-121.8783,37.9)] |Oakland -Pimlico Dr |[(-121.8616,37.998),(-121.8618,37.008)] |Oakland -Rosedale Ct |[(-121.9232,37.9),(-121.924,37.897)] |Oakland -Saginaw Ct |[(-121.8803,37.898),(-121.8806,37.901)] |Oakland -Sp Railroad |[(-121.893564,37.99009),(-121.897,37.016)] |Oakland -Sp Railroad |[(-121.9565,37.898),(-121.9562,37.9)] |Oakland -State Hwy 84 |[(-121.9565,37.898),(-121.956589,37.89911),(-121.9569,37.903),(-121.956,37.91),(-121.9553,37.919)] |Oakland -Sunol Ridge Trl |[(-121.9419,37.455),(-121.9345,37.38)] |Oakland -Tassajara Creek |[(-121.87866,37.98898),(-121.8782,37.015)] |Oakland -Theresa Way |[(-121.7289,37.906),(-121.728,37.899)] |Oakland -Tissiack Way |[(-121.920364,37),(-121.9208,37.995)] |Oakland -Vallecitos Road|[(-121.8699,37.916),(-121.8703,37.891)] |Oakland -Warm Springs Blvd|[(-121.933956,37),(-121.9343,37.97)] |Oakland -Welch Creek Road|[(-121.7695,37.386),(-121.7737,37.413)] |Oakland -Whitlock Creek |[(-121.74683,37.91276),(-121.733107,37)] |Oakland -1st St |[(-121.75508,37.89294),(-121.753581,37.90031)] |Oakland -Arden Road|[(-122.0978,37.177),(-122.1,37.177)] |Oakland -Ash St |[(-122.0408,37.31),(-122.04,37.292)] |Oakland -Bridgepointe Dr |[(-122.0514,37.305),(-122.0509,37.299)] |Oakland -Butterfield Dr |[(-122.0838,37.002),(-122.0834,37.987)] |Oakland -Celia St |[(-122.0611,37.3),(-122.0616,37.299)] |Oakland -Claremont Pl |[(-122.0542,37.995),(-122.0542,37.008)] |Oakland -Crystaline Dr |[(-121.925856,37),(-121.925869,37.00527)] |Oakland -Decoto Road|[(-122.0159,37.006),(-122.016,37.002),(-122.0164,37.993)] |Oakland -Eden Creek |[(-122.022037,37.00675),(-122.0221,37.998)] |Oakland -Hesperian Blvd|[(-122.097,37.333),(-122.0956,37.31),(-122.0946,37.293)] |Oakland -I- 580 |[(-121.727,37.074),(-121.7229,37.093),(-121.722301,37.09522),(-121.721001,37.10005),(-121.7194,37.106),(-121.7188,37.109),(-121.7168,37.12),(-121.7163,37.123),(-121.7145,37.127),(-121.7096,37.148),(-121.707731,37.1568),(-121.7058,37.166),(-121.7055,37.168),(-121.7044,37.174),(-121.7038,37.172),(-121.7037,37.172),(-121.7027,37.175),(-121.7001,37.181),(-121.6957,37.191),(-121.6948,37.192),(-121.6897,37.204),(-121.6697,37.185)]|Oakland -I- 680 |((-121.939,37.15),(-121.9387,37.145),(-121.9373,37.125),(-121.934242,37.07643),(-121.933886,37.0709),(-121.9337,37.068),(-121.933122,37.06139),(-121.932736,37.05698),(-121.93222,37.05108),(-121.931844,37.04678),(-121.930113,37.027),(-121.926829,37),(-121.9265,37.998),(-121.9217,37.96),(-121.9203,37.949),(-121.9184,37.934)) |Oakland -I- 880 |((-121.9669,37.075),(-121.9663,37.071),(-121.9656,37.065),(-121.9618,37.037),(-121.95689,37),(-121.948,37.933)) |Oakland -I- 880 |[(-122.0612,37.003),(-122.0604,37.991),(-122.0596,37.982),(-122.0585,37.967),(-122.0583,37.961),(-122.0553,37.918),(-122.053635,37.89475),(-122.050759,37.8546),(-122.05,37.844),(-122.0485,37.817),(-122.0483,37.813),(-122.0482,37.811)] |Oakland -I- 880 |[(-122.0831,37.312),(-122.0819,37.296),(-122.081,37.285),(-122.0786,37.248),(-122.078,37.24),(-122.077642,37.23496),(-122.076983,37.22567),(-122.076599,37.22026),(-122.076229,37.21505),(-122.0758,37.209)] |Oakland -I- 880 Ramp|[(-122.0019,37.301),(-122.002,37.293)] |Oakland -I- 880 Ramp|[(-122.0041,37.313),(-122.0018,37.315),(-122.0007,37.315),(-122.0005,37.313),(-122.0002,37.308),(-121.9995,37.289)] |Oakland -I- 880 Ramp|[(-122.0041,37.313),(-122.0038,37.308),(-122.0039,37.284),(-122.0013,37.287),(-121.9995,37.289)] |Oakland -I- 880 Ramp|[(-122.059,37.982),(-122.0577,37.984),(-122.0612,37.003)] |Oakland -I- 880 Ramp|[(-122.0618,37.011),(-122.0631,37.982),(-122.0585,37.967)] |Oakland -I- 880 Ramp|[(-122.085,37.34),(-122.0801,37.316),(-122.081,37.285)] |Oakland -I- 880 Ramp|[(-122.085,37.34),(-122.0866,37.316),(-122.0819,37.296)] |Oakland -Kildare Road|[(-122.0968,37.016),(-122.0959,37)] |Oakland -Mildred Ct |[(-122.0002,37.388),(-121.9998,37.386)] |Oakland -Miramar Ave |[(-122.1009,37.025),(-122.099089,37.03209)] |Oakland -Mission Blvd|[(-121.918886,37),(-121.9194,37.976),(-121.9198,37.975)] |Oakland -Moores Ave |[(-122.0087,37.301),(-122.0094,37.292)] |Oakland -Oakridge Road|[(-121.8316,37.049),(-121.828382,37)] |Oakland -Paseo Padre Pkwy|[(-121.9143,37.005),(-121.913522,37)] |Oakland -Periwinkle Road|[(-122.0451,37.301),(-122.044758,37.29844)] |Oakland -Railroad Ave |[(-122.0245,37.013),(-122.0234,37.003),(-122.0223,37.993)] |Oakland -Ranspot Dr |[(-122.0972,37.999),(-122.0959,37)] |Oakland -Santa Maria Ave |[(-122.0773,37),(-122.0773,37.98)] |Oakland -Sp Railroad |[(-122.0734,37.001),(-122.0734,37.997)] |Oakland -Stanton Ave |[(-122.100392,37.0697),(-122.099513,37.06052)] |Oakland -Thackeray Ave |[(-122.072,37.305),(-122.0715,37.298)] |Oakland -Tissiack Way |[(-121.920364,37),(-121.9208,37.995)] |Oakland -Warm Springs Blvd|[(-121.933956,37),(-121.9343,37.97)] |Oakland -Western Pacific Railroad Spur |[(-122.0394,37.018),(-122.0394,37.961)] |Oakland -Whitlock Creek |[(-121.74683,37.91276),(-121.733107,37)] |Oakland -Avenue 134th |[(-122.1823,37.002),(-122.1851,37.992)] |Oakland -Avenue 140th |[(-122.1656,37.003),(-122.1691,37.988)] |Oakland -B St |[(-122.1749,37.451),(-122.1743,37.443)] |Oakland -Bancroft Ave |[(-122.15714,37.4242),(-122.156,37.409)] |Oakland -Bancroft Ave |[(-122.1643,37.523),(-122.1631,37.508),(-122.1621,37.493)] |Oakland -Birch St |[(-122.1617,37.425),(-122.1614,37.417)] |Oakland -Birch St |[(-122.1673,37.509),(-122.1661,37.492)] |Oakland -Broadmore Ave |[(-122.095,37.522),(-122.0936,37.497)] |Oakland -Butterfield Dr |[(-122.0838,37.002),(-122.0834,37.987)] |Oakland -C St |[(-122.1768,37.46),(-122.1749,37.435)] |Oakland -Cameron Ave |[(-122.1316,37.502),(-122.1327,37.481)] |Oakland -Chapman Dr |[(-122.0421,37.504),(-122.0414,37.498)] |Oakland -Charles St |[(-122.0255,37.505),(-122.0252,37.499)] |Oakland -Claremont Pl |[(-122.0542,37.995),(-122.0542,37.008)] |Oakland -Coliseum Way |[(-122.2001,37.47),(-122.1978,37.516)] |Oakland -D St |[(-122.1811,37.505),(-122.1805,37.497)] |Oakland -Decoto Road|[(-122.0159,37.006),(-122.016,37.002),(-122.0164,37.993)] |Oakland -E St |[(-122.1832,37.505),(-122.1826,37.498),(-122.182,37.49)] |Oakland -Eden Ave |[(-122.1143,37.505),(-122.1142,37.491)] |Oakland -Eden Creek |[(-122.022037,37.00675),(-122.0221,37.998)] |Oakland -Hegenberger Exwy|[(-122.1946,37.52),(-122.1947,37.497)] |Oakland -Herrier St |[(-122.1943,37.006),(-122.1936,37.998)] |Oakland -I- 580 |[(-122.1108,37.023),(-122.1101,37.02),(-122.108103,37.00764),(-122.108,37.007),(-122.1069,37.998),(-122.1064,37.994),(-122.1053,37.982),(-122.1048,37.977),(-122.1032,37.958),(-122.1026,37.953),(-122.1013,37.938),(-122.0989,37.911),(-122.0984,37.91),(-122.098,37.908)] |Oakland -I- 580 |[(-122.1543,37.703),(-122.1535,37.694),(-122.1512,37.655),(-122.1475,37.603),(-122.1468,37.583),(-122.1472,37.569),(-122.149044,37.54874),(-122.1493,37.546),(-122.1501,37.532),(-122.1506,37.509),(-122.1495,37.482),(-122.1487,37.467),(-122.1477,37.447),(-122.1414,37.383),(-122.1404,37.376),(-122.1398,37.372),(-122.139,37.356),(-122.1388,37.353),(-122.1385,37.34),(-122.1382,37.33),(-122.1378,37.316)] |Oakland -I- 580 Ramp|[(-122.1086,37.003),(-122.1068,37.993),(-122.1066,37.992),(-122.1053,37.982)] |Oakland -I- 580 Ramp|[(-122.1414,37.383),(-122.1407,37.376),(-122.1403,37.372),(-122.139,37.356)] |Oakland -I- 880 |[(-122.0375,37.632),(-122.0359,37.619),(-122.0358,37.616),(-122.034514,37.60409),(-122.031876,37.57965),(-122.031193,37.57332),(-122.03016,37.56375),(-122.02943,37.55698),(-122.028689,37.54929),(-122.027833,37.53908),(-122.025979,37.51698),(-122.0238,37.491)] |Oakland -I- 880 |[(-122.0612,37.003),(-122.0604,37.991),(-122.0596,37.982),(-122.0585,37.967),(-122.0583,37.961),(-122.0553,37.918),(-122.053635,37.89475),(-122.050759,37.8546),(-122.05,37.844),(-122.0485,37.817),(-122.0483,37.813),(-122.0482,37.811)] |Oakland -I- 880 |[(-122.0978,37.528),(-122.096,37.496),(-122.0931,37.453),(-122.09277,37.4496),(-122.090189,37.41442),(-122.0896,37.405),(-122.085,37.34)] |Oakland -I- 880 |[(-122.1755,37.185),(-122.1747,37.178),(-122.1742,37.173),(-122.1692,37.126),(-122.167792,37.11594),(-122.16757,37.11435),(-122.1671,37.111),(-122.1655,37.1),(-122.165169,37.09811),(-122.1641,37.092),(-122.1596,37.061),(-122.158381,37.05275),(-122.155991,37.03657),(-122.1531,37.017),(-122.1478,37.98),(-122.1407,37.932),(-122.1394,37.924),(-122.1389,37.92),(-122.1376,37.91)] |Oakland -I- 880 Ramp|[(-122.059,37.982),(-122.0577,37.984),(-122.0612,37.003)] |Oakland -I- 880 Ramp|[(-122.0618,37.011),(-122.0631,37.982),(-122.0585,37.967)] |Oakland -Kaiser Dr |[(-122.067163,37.47821),(-122.060402,37.51961)] |Oakland -La Playa Dr |[(-122.1039,37.545),(-122.101,37.493)] |Oakland -Locust St |[(-122.1606,37.007),(-122.1593,37.987)] |Oakland -Magnolia St |[(-122.0971,37.5),(-122.0962,37.484)] |Oakland -Mattos Dr |[(-122.0005,37.502),(-122.000898,37.49683)] |Oakland -Maubert Ave |[(-122.1114,37.009),(-122.1096,37.995)] |Oakland -McClure Ave |[(-122.1431,37.001),(-122.1436,37.998)] |Oakland -National Ave |[(-122.1192,37.5),(-122.1281,37.489)] |Oakland -Portsmouth Ave |[(-122.1064,37.315),(-122.1064,37.308)] |Oakland -Railroad Ave |[(-122.0245,37.013),(-122.0234,37.003),(-122.0223,37.993)] |Oakland -Ranspot Dr |[(-122.0972,37.999),(-122.0959,37)] |Oakland -Redwood Road|[(-122.1493,37.98),(-122.1437,37.001)] |Oakland -Santa Maria Ave |[(-122.0773,37),(-122.0773,37.98)] |Oakland -Skyline Blvd|[(-122.1738,37.01),(-122.1714,37.996)] |Oakland -Skyline Dr |[(-122.0277,37.5),(-122.0284,37.498)] |Oakland -Sp Railroad |[(-122.0734,37.001),(-122.0734,37.997)] |Oakland -Sp Railroad |[(-122.137792,37.003),(-122.1365,37.992),(-122.131257,37.94612)] |Oakland -Sp Railroad |[(-122.1947,37.497),(-122.193328,37.4848)] |Oakland -State Hwy 92 |[(-122.1085,37.326),(-122.1095,37.322),(-122.1111,37.316),(-122.1119,37.313),(-122.1125,37.311),(-122.1131,37.308),(-122.1167,37.292),(-122.1187,37.285),(-122.12,37.28)] |Oakland -State Hwy 92 Ramp|[(-122.1086,37.321),(-122.1089,37.315),(-122.1111,37.316)] |Oakland -Western Pacific Railroad Spur |[(-122.0394,37.018),(-122.0394,37.961)] |Oakland -Willimet Way |[(-122.0964,37.517),(-122.0949,37.493)] |Oakland -Wisconsin St |[(-122.1994,37.017),(-122.1975,37.998),(-122.1971,37.994)] |Oakland -100th Ave |[(-122.1657,37.429),(-122.1647,37.432)] |Oakland -107th Ave |[(-122.1555,37.403),(-122.1531,37.41)] |Oakland -85th Ave |[(-122.1877,37.466),(-122.186,37.476)] |Oakland -89th Ave |[(-122.1822,37.459),(-122.1803,37.471)] |Oakland -98th Ave |[(-122.1568,37.498),(-122.1558,37.502)] |Oakland -98th Ave |[(-122.1693,37.438),(-122.1682,37.444)] |Oakland -Allen Ct |[(-122.0131,37.602),(-122.0117,37.597)] |Berkeley -Alvarado Niles Road|[(-122.0325,37.903),(-122.0316,37.9)] |Berkeley -Arizona St |[(-122.0381,37.901),(-122.0367,37.898)] |Berkeley -Avenue 134th |[(-122.1823,37.002),(-122.1851,37.992)] |Berkeley -Avenue 140th |[(-122.1656,37.003),(-122.1691,37.988)] |Berkeley -Broadway |[(-122.2409,37.586),(-122.2395,37.601)] |Berkeley -Buckingham Blvd|[(-122.2231,37.59),(-122.2214,37.606)] |Berkeley -Butterfield Dr |[(-122.0838,37.002),(-122.0834,37.987)] |Berkeley -California St |[(-122.2032,37.005),(-122.2016,37.996)] |Berkeley -Campus Dr |[(-122.1704,37.905),(-122.1678,37.868),(-122.1671,37.865)] |Berkeley -Carson St |[(-122.1846,37.9),(-122.1843,37.901)] |Berkeley -Central Ave |[(-122.2343,37.602),(-122.2331,37.595)] |Berkeley -Champion St |[(-122.214,37.991),(-122.2147,37.002)] |Berkeley -Claremont Pl |[(-122.0542,37.995),(-122.0542,37.008)] |Berkeley -Coliseum Way |[(-122.2113,37.626),(-122.2085,37.592),(-122.2063,37.568)] |Berkeley -Cornell Ave |[(-122.2956,37.925),(-122.2949,37.906),(-122.2939,37.875)] |Berkeley -Creston Road|[(-122.2639,37.002),(-122.2613,37.986),(-122.2602,37.978),(-122.2598,37.973)] |Berkeley -Crow Canyon Creek |[(-122.043,37.905),(-122.0368,37.71)] |Berkeley -Cull Creek |[(-122.0624,37.875),(-122.0582,37.527)] |Berkeley -Decoto Road|[(-122.0159,37.006),(-122.016,37.002),(-122.0164,37.993)] |Berkeley -Deering St |[(-122.2146,37.904),(-122.2126,37.897)] |Berkeley -Dimond Ave |[(-122.2167,37.994),(-122.2162,37.006)] |Berkeley -Donna Way |[(-122.1333,37.606),(-122.1316,37.599)] |Berkeley -Eden Creek |[(-122.022037,37.00675),(-122.0221,37.998)] |Berkeley -Euclid Ave |[(-122.2671,37.009),(-122.2666,37.987)] |Berkeley -Foothill Blvd|[(-122.2414,37.9),(-122.2403,37.893)] |Berkeley -Fountain St |[(-122.2306,37.593),(-122.2293,37.605)] |Berkeley -Grizzly Peak Blvd|[(-122.2213,37.638),(-122.2127,37.581)] |Berkeley -Grove Way |[(-122.0643,37.884),(-122.062679,37.89162),(-122.061796,37.89578),(-122.0609,37.9)] |Berkeley -Herrier St |[(-122.1943,37.006),(-122.1936,37.998)] |Berkeley -Hesperian Blvd|[(-122.1132,37.6),(-122.1123,37.586)] |Berkeley -I- 580 |[(-122.1108,37.023),(-122.1101,37.02),(-122.108103,37.00764),(-122.108,37.007),(-122.1069,37.998),(-122.1064,37.994),(-122.1053,37.982),(-122.1048,37.977),(-122.1032,37.958),(-122.1026,37.953),(-122.1013,37.938),(-122.0989,37.911),(-122.0984,37.91),(-122.098,37.908)] |Berkeley -I- 580 |[(-122.1543,37.703),(-122.1535,37.694),(-122.1512,37.655),(-122.1475,37.603),(-122.1468,37.583),(-122.1472,37.569),(-122.149044,37.54874),(-122.1493,37.546),(-122.1501,37.532),(-122.1506,37.509),(-122.1495,37.482),(-122.1487,37.467),(-122.1477,37.447),(-122.1414,37.383),(-122.1404,37.376),(-122.1398,37.372),(-122.139,37.356),(-122.1388,37.353),(-122.1385,37.34),(-122.1382,37.33),(-122.1378,37.316)] |Berkeley -I- 580 |[(-122.2197,37.99),(-122.22,37.99),(-122.222092,37.99523),(-122.2232,37.998),(-122.224146,37.99963),(-122.2261,37.003),(-122.2278,37.007),(-122.2302,37.026),(-122.2323,37.043),(-122.2344,37.059),(-122.235405,37.06427),(-122.2365,37.07)] |Berkeley -I- 580 Ramp|[(-122.093241,37.90351),(-122.09364,37.89634),(-122.093788,37.89212)] |Berkeley -I- 580 Ramp|[(-122.0934,37.896),(-122.09257,37.89961),(-122.0911,37.906)] |Berkeley -I- 580 Ramp|[(-122.0941,37.897),(-122.0943,37.902)] |Berkeley -I- 580 Ramp|[(-122.096,37.888),(-122.0962,37.891),(-122.0964,37.9)] |Berkeley -I- 580 Ramp|[(-122.101,37.898),(-122.1005,37.902),(-122.0989,37.911)] |Berkeley -I- 580 Ramp|[(-122.1086,37.003),(-122.1068,37.993),(-122.1066,37.992),(-122.1053,37.982)] |Berkeley -I- 880 |[(-122.0375,37.632),(-122.0359,37.619),(-122.0358,37.616),(-122.034514,37.60409),(-122.031876,37.57965),(-122.031193,37.57332),(-122.03016,37.56375),(-122.02943,37.55698),(-122.028689,37.54929),(-122.027833,37.53908),(-122.025979,37.51698),(-122.0238,37.491)] |Berkeley -I- 880 |[(-122.0612,37.003),(-122.0604,37.991),(-122.0596,37.982),(-122.0585,37.967),(-122.0583,37.961),(-122.0553,37.918),(-122.053635,37.89475),(-122.050759,37.8546),(-122.05,37.844),(-122.0485,37.817),(-122.0483,37.813),(-122.0482,37.811)] |Berkeley -I- 880 |[(-122.1365,37.902),(-122.1358,37.898),(-122.1333,37.881),(-122.1323,37.874),(-122.1311,37.866),(-122.1308,37.865),(-122.1307,37.864),(-122.1289,37.851),(-122.1277,37.843),(-122.1264,37.834),(-122.1231,37.812),(-122.1165,37.766),(-122.1104,37.72),(-122.109695,37.71094),(-122.109,37.702),(-122.108312,37.69168),(-122.1076,37.681)] |Berkeley -I- 880 |[(-122.1755,37.185),(-122.1747,37.178),(-122.1742,37.173),(-122.1692,37.126),(-122.167792,37.11594),(-122.16757,37.11435),(-122.1671,37.111),(-122.1655,37.1),(-122.165169,37.09811),(-122.1641,37.092),(-122.1596,37.061),(-122.158381,37.05275),(-122.155991,37.03657),(-122.1531,37.017),(-122.1478,37.98),(-122.1407,37.932),(-122.1394,37.924),(-122.1389,37.92),(-122.1376,37.91)] |Berkeley -I- 880 |[(-122.2214,37.711),(-122.2202,37.699),(-122.2199,37.695),(-122.219,37.682),(-122.2184,37.672),(-122.2173,37.652),(-122.2159,37.638),(-122.2144,37.616),(-122.2138,37.612),(-122.2135,37.609),(-122.212,37.592),(-122.2116,37.586),(-122.2111,37.581)] |Berkeley -I- 880 |[(-122.2707,37.975),(-122.2693,37.972),(-122.2681,37.966),(-122.267,37.962),(-122.2659,37.957),(-122.2648,37.952),(-122.2636,37.946),(-122.2625,37.935),(-122.2617,37.927),(-122.2607,37.921),(-122.2593,37.916),(-122.258,37.911),(-122.2536,37.898),(-122.2432,37.858),(-122.2408,37.845),(-122.2386,37.827),(-122.2374,37.811)] |Berkeley -I- 880 Ramp|[(-122.059,37.982),(-122.0577,37.984),(-122.0612,37.003)] |Berkeley -I- 880 Ramp|[(-122.0618,37.011),(-122.0631,37.982),(-122.0585,37.967)] |Berkeley -I- 880 Ramp|[(-122.1029,37.61),(-122.1013,37.587),(-122.0999,37.569)] |Berkeley -I- 880 Ramp|[(-122.1379,37.891),(-122.1383,37.897),(-122.1377,37.902)] |Berkeley -I- 880 Ramp|[(-122.1379,37.931),(-122.137597,37.92736),(-122.1374,37.925),(-122.1373,37.924),(-122.1369,37.914),(-122.1358,37.905),(-122.1365,37.908),(-122.1358,37.898)] |Berkeley -I- 880 Ramp|[(-122.2536,37.898),(-122.254,37.902)] |Berkeley -Jackson St |[(-122.0845,37.6),(-122.0842,37.606)] |Berkeley -Joyce St |[(-122.0792,37.604),(-122.0774,37.581)] |Berkeley -Keeler Ave |[(-122.2578,37.906),(-122.2579,37.899)] |Berkeley -Laguna Ave |[(-122.2099,37.989),(-122.2089,37)] |Berkeley -Lakehurst Cir |[(-122.284729,37.89025),(-122.286096,37.90364)] |Berkeley -Lakeshore Ave |[(-122.2586,37.99),(-122.2556,37.006)] |Berkeley -Linden St |[(-122.2867,37.998),(-122.2864,37.008)] |Berkeley -Locust St |[(-122.1606,37.007),(-122.1593,37.987)] |Berkeley -Marin Ave |[(-122.2741,37.894),(-122.272,37.901)] |Berkeley -Martin Luther King Jr Way |[(-122.2712,37.608),(-122.2711,37.599)] |Berkeley -Maubert Ave |[(-122.1114,37.009),(-122.1096,37.995)] |Berkeley -McClure Ave |[(-122.1431,37.001),(-122.1436,37.998)] |Berkeley -Miller Road|[(-122.0902,37.645),(-122.0865,37.545)] |Berkeley -Mission Blvd|[(-122.0006,37.896),(-121.9989,37.88)] |Berkeley -Oakland Inner Harbor |[(-122.2625,37.913),(-122.260016,37.89484)] |Berkeley -Oneil Ave |[(-122.076754,37.62476),(-122.0745,37.595)] |Berkeley -Parkridge Dr |[(-122.1438,37.884),(-122.1428,37.9)] |Berkeley -Parkside Dr |[(-122.0475,37.603),(-122.0443,37.596)] |Berkeley -Paseo Padre Pkwy|[(-122.0021,37.639),(-121.996,37.628)] |Berkeley -Pearl St |[(-122.2383,37.594),(-122.2366,37.615)] |Berkeley -Railroad Ave |[(-122.0245,37.013),(-122.0234,37.003),(-122.0223,37.993)] |Berkeley -Ranspot Dr |[(-122.0972,37.999),(-122.0959,37)] |Berkeley -Redding St |[(-122.1978,37.901),(-122.1975,37.895)] |Berkeley -Redwood Road|[(-122.1493,37.98),(-122.1437,37.001)] |Berkeley -Roca Dr |[(-122.0335,37.609),(-122.0314,37.599)] |Berkeley -Sacramento St |[(-122.2799,37.606),(-122.2797,37.597)] |Berkeley -Saddle Brook Dr |[(-122.1478,37.909),(-122.1454,37.904),(-122.1451,37.888)] |Berkeley -San Andreas Dr |[(-122.0609,37.9),(-122.0614,37.895)] |Berkeley -Santa Maria Ave |[(-122.0773,37),(-122.0773,37.98)] |Berkeley -Shattuck Ave |[(-122.2686,37.904),(-122.2686,37.897)] |Berkeley -Shoreline Dr |[(-122.2657,37.603),(-122.2648,37.6)] |Berkeley -Skyline Blvd|[(-122.1738,37.01),(-122.1714,37.996)] |Berkeley -Skywest Dr |[(-122.1161,37.62),(-122.1123,37.586)] |Berkeley -Sp Railroad |[(-122.0734,37.001),(-122.0734,37.997)] |Berkeley -Sp Railroad |[(-122.0914,37.601),(-122.087,37.56),(-122.086408,37.5551)] |Berkeley -Sp Railroad |[(-122.137792,37.003),(-122.1365,37.992),(-122.131257,37.94612)] |Berkeley -State Hwy 123 |[(-122.3004,37.986),(-122.2998,37.969),(-122.2995,37.962),(-122.2992,37.952),(-122.299,37.942),(-122.2987,37.935),(-122.2984,37.924),(-122.2982,37.92),(-122.2976,37.904),(-122.297,37.88),(-122.2966,37.869),(-122.2959,37.848),(-122.2961,37.843)] |Berkeley -State Hwy 13 |[(-122.1797,37.943),(-122.179871,37.91849),(-122.18,37.9),(-122.179023,37.86615),(-122.1787,37.862),(-122.1781,37.851),(-122.1777,37.845),(-122.1773,37.839),(-122.177,37.833)] |Berkeley -State Hwy 238 |((-122.098,37.908),(-122.0983,37.907),(-122.099,37.905),(-122.101,37.898),(-122.101535,37.89711),(-122.103173,37.89438),(-122.1046,37.892),(-122.106,37.89)) |Berkeley -State Hwy 238 Ramp|[(-122.1288,37.9),(-122.1293,37.895),(-122.1296,37.906)] |Berkeley -Stuart St |[(-122.2518,37.6),(-122.2507,37.601),(-122.2491,37.606)] |Berkeley -Tupelo Ter |[(-122.059087,37.6113),(-122.057021,37.59942)] |Berkeley -West Loop Road|[(-122.0576,37.604),(-122.0602,37.586)] |Berkeley -Western Pacific Railroad Spur |[(-122.0394,37.018),(-122.0394,37.961)] |Berkeley -Wisconsin St |[(-122.1994,37.017),(-122.1975,37.998),(-122.1971,37.994)] |Berkeley -Wp Railroad |[(-122.254,37.902),(-122.2506,37.891)] |Berkeley -19th Ave |[(-122.2366,37.897),(-122.2359,37.905)] |Berkeley -5th St |[(-122.296,37.615),(-122.2953,37.598)] |Berkeley -82nd Ave |[(-122.1695,37.596),(-122.1681,37.603)] |Berkeley -Ada St |[(-122.2487,37.398),(-122.2496,37.401)] |Lafayette -California St |[(-122.2032,37.005),(-122.2016,37.996)] |Lafayette -Capricorn Ave |[(-122.2176,37.404),(-122.2164,37.384)] |Lafayette -Chambers Dr |[(-122.2004,37.352),(-122.1972,37.368)] |Lafayette -Chambers Lane|[(-122.2001,37.359),(-122.1975,37.371)] |Lafayette -Champion St |[(-122.214,37.991),(-122.2147,37.002)] |Lafayette -Coolidge Ave |[(-122.2007,37.058),(-122.1992,37.06)] |Lafayette -Creston Road|[(-122.2639,37.002),(-122.2613,37.986),(-122.2602,37.978),(-122.2598,37.973)] |Lafayette -Dimond Ave |[(-122.2167,37.994),(-122.2162,37.006)] |Lafayette -Edgewater Dr |[(-122.201,37.379),(-122.2042,37.41)] |Lafayette -Euclid Ave |[(-122.2671,37.009),(-122.2666,37.987)] |Lafayette -Heartwood Dr |[(-122.2006,37.341),(-122.1992,37.338)] |Lafayette -Hollis St |[(-122.2885,37.397),(-122.289,37.414)] |Lafayette -I- 580 |[(-122.2197,37.99),(-122.22,37.99),(-122.222092,37.99523),(-122.2232,37.998),(-122.224146,37.99963),(-122.2261,37.003),(-122.2278,37.007),(-122.2302,37.026),(-122.2323,37.043),(-122.2344,37.059),(-122.235405,37.06427),(-122.2365,37.07)] |Lafayette -I- 80 Ramp|[(-122.2962,37.413),(-122.2959,37.382),(-122.2951,37.372)] |Lafayette -I- 880 Ramp|[(-122.2771,37.002),(-122.278,37)] |Lafayette -Indian Way |[(-122.2066,37.398),(-122.2045,37.411)] |Lafayette -Laguna Ave |[(-122.2099,37.989),(-122.2089,37)] |Lafayette -Lakeshore Ave |[(-122.2586,37.99),(-122.2556,37.006)] |Lafayette -Linden St |[(-122.2867,37.998),(-122.2864,37.008)] |Lafayette -Mandalay Road|[(-122.2322,37.397),(-122.2321,37.403)] |Lafayette -Proctor Ave |[(-122.2267,37.406),(-122.2251,37.386)] |Lafayette -Sheridan Road|[(-122.2279,37.425),(-122.2253,37.411),(-122.2223,37.377)] |Lafayette -State Hwy 13 |[(-122.2049,37.2),(-122.20328,37.17975),(-122.1989,37.125),(-122.198078,37.11641),(-122.1975,37.11)] |Lafayette -State Hwy 13 Ramp|[(-122.2244,37.427),(-122.223,37.414),(-122.2214,37.396),(-122.2213,37.388)] |Lafayette -State Hwy 24 |[(-122.2674,37.246),(-122.2673,37.248),(-122.267,37.261),(-122.2668,37.271),(-122.2663,37.298),(-122.2659,37.315),(-122.2655,37.336),(-122.265007,37.35882),(-122.264443,37.37286),(-122.2641,37.381),(-122.2638,37.388),(-122.2631,37.396),(-122.2617,37.405),(-122.2615,37.407),(-122.2605,37.412)] |Lafayette -Taurus Ave |[(-122.2159,37.416),(-122.2128,37.389)] |Lafayette -5th St |[(-122.278,37),(-122.2792,37.005),(-122.2803,37.009)] |Lafayette -98th Ave |[(-122.2001,37.258),(-122.1974,37.27)] |Lafayette +-- +-- SELECT_VIEWS +-- test the views defined in CREATE_VIEWS +-- +SELECT * FROM street; + name | thepath | cname +------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+----------- + Access Rd 25 | [(-121.9283,37.894),(-121.9283,37.9)] | Oakland + Agua Fria Creek | [(-121.9254,37.922),(-121.9281,37.889)] | Oakland + Andrea Cir | [(-121.733218,37.88641),(-121.733286,37.90617)] | Oakland + Apricot Lane | [(-121.9471,37.401),(-121.9456,37.392)] | Oakland + Arlington Dr | [(-121.8802,37.408),(-121.8807,37.394)] | Oakland + Arlington Road | [(-121.7957,37.898),(-121.7956,37.906)] | Oakland + Arroyo Las Positas | [(-121.7973,37.997),(-121.7957,37.005)] | Oakland + Arroyo Seco | [(-121.7073,37.766),(-121.6997,37.729)] | Oakland + Calaveras Creek | [(-121.8203,37.035),(-121.8207,37.931)] | Oakland + Corriea Way | [(-121.9501,37.402),(-121.9505,37.398)] | Oakland + Cowing Road | [(-122.0002,37.934),(-121.9772,37.782)] | Oakland + Driscoll Road | [(-121.9482,37.403),(-121.948451,37.39995)] | Oakland + Enos Way | [(-121.7677,37.896),(-121.7673,37.91)] | Oakland + Fairview Ave | [(-121.999,37.428),(-121.9863,37.351)] | Oakland + I- 580 | [(-121.9322,37.989),(-121.9243,37.006),(-121.9217,37.014)] | Oakland + I- 580 | [(-122.018,37.019),(-122.0009,37.032),(-121.9787,37.983),(-121.958,37.984),(-121.9571,37.986)] | Oakland + I- 580 Ramp | [(-121.8521,37.011),(-121.8479,37.999),(-121.8476,37.999),(-121.8456,37.01),(-121.8455,37.011)] | Oakland + I- 580 Ramp | [(-121.8743,37.014),(-121.8722,37.999),(-121.8714,37.999)] | Oakland + I- 580 Ramp | [(-121.9043,37.998),(-121.9036,37.013),(-121.902632,37.0174),(-121.9025,37.018)] | Oakland + I- 580 Ramp | [(-121.9368,37.986),(-121.936483,37.98832),(-121.9353,37.997),(-121.93504,37.00035),(-121.9346,37.006),(-121.933764,37.00031),(-121.9333,37.997),(-121.9322,37.989)] | Oakland + I- 580/I-680 Ramp | ((-121.9207,37.988),(-121.9192,37.016)) | Oakland + I- 680 | ((-121.939,37.15),(-121.9387,37.145),(-121.9373,37.125),(-121.934242,37.07643),(-121.933886,37.0709),(-121.9337,37.068),(-121.933122,37.06139),(-121.932736,37.05698),(-121.93222,37.05108),(-121.931844,37.04678),(-121.930113,37.027),(-121.926829,37),(-121.9265,37.998),(-121.9217,37.96),(-121.9203,37.949),(-121.9184,37.934)) | Oakland + I- 680 | [(-121.9101,37.715),(-121.911269,37.74682),(-121.9119,37.764),(-121.9124,37.776),(-121.9174,37.905),(-121.9194,37.957),(-121.9207,37.988)] | Oakland + I- 680 | [(-121.9184,37.934),(-121.917,37.913),(-121.9122,37.83),(-121.9052,37.702)] | Oakland + I- 680 Ramp | [(-121.8833,37.376),(-121.8833,37.392),(-121.883,37.4),(-121.8835,37.402),(-121.8852,37.422)] | Oakland + I- 680 Ramp | [(-121.92,37.438),(-121.9218,37.424),(-121.9238,37.408),(-121.9252,37.392)] | Oakland + I- 680 Ramp | [(-121.9238,37.402),(-121.9234,37.395),(-121.923,37.399)] | Oakland + I- 880 | ((-121.9669,37.075),(-121.9663,37.071),(-121.9656,37.065),(-121.9618,37.037),(-121.95689,37),(-121.948,37.933)) | Oakland + I- 880 | [(-121.948,37.933),(-121.9471,37.925),(-121.9467,37.923),(-121.946,37.918),(-121.9452,37.912),(-121.937,37.852)] | Oakland + Johnson Dr | [(-121.9145,37.901),(-121.915,37.877)] | Oakland + Juniper St | [(-121.7823,37.897),(-121.7815,37.9)] | Oakland + Las Positas Road | [(-121.764488,37.99199),(-121.75569,37.02022)] | Oakland + Livermore Ave | [(-121.7687,37.448),(-121.769,37.375)] | Oakland + Livermore Ave | [(-121.772719,37.99085),(-121.7728,37.001)] | Oakland + Mission Blvd | [(-121.918886,37),(-121.9194,37.976),(-121.9198,37.975)] | Oakland + Navajo Ct | [(-121.8779,37.901),(-121.8783,37.9)] | Oakland + Pimlico Dr | [(-121.8616,37.998),(-121.8618,37.008)] | Oakland + Rosedale Ct | [(-121.9232,37.9),(-121.924,37.897)] | Oakland + Saginaw Ct | [(-121.8803,37.898),(-121.8806,37.901)] | Oakland + Sp Railroad | [(-121.893564,37.99009),(-121.897,37.016)] | Oakland + Sp Railroad | [(-121.9565,37.898),(-121.9562,37.9)] | Oakland + State Hwy 84 | [(-121.9565,37.898),(-121.956589,37.89911),(-121.9569,37.903),(-121.956,37.91),(-121.9553,37.919)] | Oakland + Sunol Ridge Trl | [(-121.9419,37.455),(-121.9345,37.38)] | Oakland + Tassajara Creek | [(-121.87866,37.98898),(-121.8782,37.015)] | Oakland + Theresa Way | [(-121.7289,37.906),(-121.728,37.899)] | Oakland + Tissiack Way | [(-121.920364,37),(-121.9208,37.995)] | Oakland + Vallecitos Road | [(-121.8699,37.916),(-121.8703,37.891)] | Oakland + Warm Springs Blvd | [(-121.933956,37),(-121.9343,37.97)] | Oakland + Welch Creek Road | [(-121.7695,37.386),(-121.7737,37.413)] | Oakland + Whitlock Creek | [(-121.74683,37.91276),(-121.733107,37)] | Oakland + 1st St | [(-121.75508,37.89294),(-121.753581,37.90031)] | Oakland + Arden Road | [(-122.0978,37.177),(-122.1,37.177)] | Oakland + Ash St | [(-122.0408,37.31),(-122.04,37.292)] | Oakland + Bridgepointe Dr | [(-122.0514,37.305),(-122.0509,37.299)] | Oakland + Butterfield Dr | [(-122.0838,37.002),(-122.0834,37.987)] | Oakland + Celia St | [(-122.0611,37.3),(-122.0616,37.299)] | Oakland + Claremont Pl | [(-122.0542,37.995),(-122.0542,37.008)] | Oakland + Crystaline Dr | [(-121.925856,37),(-121.925869,37.00527)] | Oakland + Decoto Road | [(-122.0159,37.006),(-122.016,37.002),(-122.0164,37.993)] | Oakland + Eden Creek | [(-122.022037,37.00675),(-122.0221,37.998)] | Oakland + Hesperian Blvd | [(-122.097,37.333),(-122.0956,37.31),(-122.0946,37.293)] | Oakland + I- 580 | [(-121.727,37.074),(-121.7229,37.093),(-121.722301,37.09522),(-121.721001,37.10005),(-121.7194,37.106),(-121.7188,37.109),(-121.7168,37.12),(-121.7163,37.123),(-121.7145,37.127),(-121.7096,37.148),(-121.707731,37.1568),(-121.7058,37.166),(-121.7055,37.168),(-121.7044,37.174),(-121.7038,37.172),(-121.7037,37.172),(-121.7027,37.175),(-121.7001,37.181),(-121.6957,37.191),(-121.6948,37.192),(-121.6897,37.204),(-121.6697,37.185)] | Oakland + I- 680 | ((-121.939,37.15),(-121.9387,37.145),(-121.9373,37.125),(-121.934242,37.07643),(-121.933886,37.0709),(-121.9337,37.068),(-121.933122,37.06139),(-121.932736,37.05698),(-121.93222,37.05108),(-121.931844,37.04678),(-121.930113,37.027),(-121.926829,37),(-121.9265,37.998),(-121.9217,37.96),(-121.9203,37.949),(-121.9184,37.934)) | Oakland + I- 880 | ((-121.9669,37.075),(-121.9663,37.071),(-121.9656,37.065),(-121.9618,37.037),(-121.95689,37),(-121.948,37.933)) | Oakland + I- 880 | [(-122.0612,37.003),(-122.0604,37.991),(-122.0596,37.982),(-122.0585,37.967),(-122.0583,37.961),(-122.0553,37.918),(-122.053635,37.89475),(-122.050759,37.8546),(-122.05,37.844),(-122.0485,37.817),(-122.0483,37.813),(-122.0482,37.811)] | Oakland + I- 880 | [(-122.0831,37.312),(-122.0819,37.296),(-122.081,37.285),(-122.0786,37.248),(-122.078,37.24),(-122.077642,37.23496),(-122.076983,37.22567),(-122.076599,37.22026),(-122.076229,37.21505),(-122.0758,37.209)] | Oakland + I- 880 Ramp | [(-122.0019,37.301),(-122.002,37.293)] | Oakland + I- 880 Ramp | [(-122.0041,37.313),(-122.0018,37.315),(-122.0007,37.315),(-122.0005,37.313),(-122.0002,37.308),(-121.9995,37.289)] | Oakland + I- 880 Ramp | [(-122.0041,37.313),(-122.0038,37.308),(-122.0039,37.284),(-122.0013,37.287),(-121.9995,37.289)] | Oakland + I- 880 Ramp | [(-122.059,37.982),(-122.0577,37.984),(-122.0612,37.003)] | Oakland + I- 880 Ramp | [(-122.0618,37.011),(-122.0631,37.982),(-122.0585,37.967)] | Oakland + I- 880 Ramp | [(-122.085,37.34),(-122.0801,37.316),(-122.081,37.285)] | Oakland + I- 880 Ramp | [(-122.085,37.34),(-122.0866,37.316),(-122.0819,37.296)] | Oakland + Kildare Road | [(-122.0968,37.016),(-122.0959,37)] | Oakland + Mildred Ct | [(-122.0002,37.388),(-121.9998,37.386)] | Oakland + Miramar Ave | [(-122.1009,37.025),(-122.099089,37.03209)] | Oakland + Mission Blvd | [(-121.918886,37),(-121.9194,37.976),(-121.9198,37.975)] | Oakland + Moores Ave | [(-122.0087,37.301),(-122.0094,37.292)] | Oakland + Oakridge Road | [(-121.8316,37.049),(-121.828382,37)] | Oakland + Paseo Padre Pkwy | [(-121.9143,37.005),(-121.913522,37)] | Oakland + Periwinkle Road | [(-122.0451,37.301),(-122.044758,37.29844)] | Oakland + Railroad Ave | [(-122.0245,37.013),(-122.0234,37.003),(-122.0223,37.993)] | Oakland + Ranspot Dr | [(-122.0972,37.999),(-122.0959,37)] | Oakland + Santa Maria Ave | [(-122.0773,37),(-122.0773,37.98)] | Oakland + Sp Railroad | [(-122.0734,37.001),(-122.0734,37.997)] | Oakland + Stanton Ave | [(-122.100392,37.0697),(-122.099513,37.06052)] | Oakland + Thackeray Ave | [(-122.072,37.305),(-122.0715,37.298)] | Oakland + Tissiack Way | [(-121.920364,37),(-121.9208,37.995)] | Oakland + Warm Springs Blvd | [(-121.933956,37),(-121.9343,37.97)] | Oakland + Western Pacific Railroad Spur | [(-122.0394,37.018),(-122.0394,37.961)] | Oakland + Whitlock Creek | [(-121.74683,37.91276),(-121.733107,37)] | Oakland + Avenue 134th | [(-122.1823,37.002),(-122.1851,37.992)] | Oakland + Avenue 140th | [(-122.1656,37.003),(-122.1691,37.988)] | Oakland + B St | [(-122.1749,37.451),(-122.1743,37.443)] | Oakland + Bancroft Ave | [(-122.15714,37.4242),(-122.156,37.409)] | Oakland + Bancroft Ave | [(-122.1643,37.523),(-122.1631,37.508),(-122.1621,37.493)] | Oakland + Birch St | [(-122.1617,37.425),(-122.1614,37.417)] | Oakland + Birch St | [(-122.1673,37.509),(-122.1661,37.492)] | Oakland + Broadmore Ave | [(-122.095,37.522),(-122.0936,37.497)] | Oakland + Butterfield Dr | [(-122.0838,37.002),(-122.0834,37.987)] | Oakland + C St | [(-122.1768,37.46),(-122.1749,37.435)] | Oakland + Cameron Ave | [(-122.1316,37.502),(-122.1327,37.481)] | Oakland + Chapman Dr | [(-122.0421,37.504),(-122.0414,37.498)] | Oakland + Charles St | [(-122.0255,37.505),(-122.0252,37.499)] | Oakland + Claremont Pl | [(-122.0542,37.995),(-122.0542,37.008)] | Oakland + Coliseum Way | [(-122.2001,37.47),(-122.1978,37.516)] | Oakland + D St | [(-122.1811,37.505),(-122.1805,37.497)] | Oakland + Decoto Road | [(-122.0159,37.006),(-122.016,37.002),(-122.0164,37.993)] | Oakland + E St | [(-122.1832,37.505),(-122.1826,37.498),(-122.182,37.49)] | Oakland + Eden Ave | [(-122.1143,37.505),(-122.1142,37.491)] | Oakland + Eden Creek | [(-122.022037,37.00675),(-122.0221,37.998)] | Oakland + Hegenberger Exwy | [(-122.1946,37.52),(-122.1947,37.497)] | Oakland + Herrier St | [(-122.1943,37.006),(-122.1936,37.998)] | Oakland + I- 580 | [(-122.1108,37.023),(-122.1101,37.02),(-122.108103,37.00764),(-122.108,37.007),(-122.1069,37.998),(-122.1064,37.994),(-122.1053,37.982),(-122.1048,37.977),(-122.1032,37.958),(-122.1026,37.953),(-122.1013,37.938),(-122.0989,37.911),(-122.0984,37.91),(-122.098,37.908)] | Oakland + I- 580 | [(-122.1543,37.703),(-122.1535,37.694),(-122.1512,37.655),(-122.1475,37.603),(-122.1468,37.583),(-122.1472,37.569),(-122.149044,37.54874),(-122.1493,37.546),(-122.1501,37.532),(-122.1506,37.509),(-122.1495,37.482),(-122.1487,37.467),(-122.1477,37.447),(-122.1414,37.383),(-122.1404,37.376),(-122.1398,37.372),(-122.139,37.356),(-122.1388,37.353),(-122.1385,37.34),(-122.1382,37.33),(-122.1378,37.316)] | Oakland + I- 580 Ramp | [(-122.1086,37.003),(-122.1068,37.993),(-122.1066,37.992),(-122.1053,37.982)] | Oakland + I- 580 Ramp | [(-122.1414,37.383),(-122.1407,37.376),(-122.1403,37.372),(-122.139,37.356)] | Oakland + I- 880 | [(-122.0375,37.632),(-122.0359,37.619),(-122.0358,37.616),(-122.034514,37.60409),(-122.031876,37.57965),(-122.031193,37.57332),(-122.03016,37.56375),(-122.02943,37.55698),(-122.028689,37.54929),(-122.027833,37.53908),(-122.025979,37.51698),(-122.0238,37.491)] | Oakland + I- 880 | [(-122.0612,37.003),(-122.0604,37.991),(-122.0596,37.982),(-122.0585,37.967),(-122.0583,37.961),(-122.0553,37.918),(-122.053635,37.89475),(-122.050759,37.8546),(-122.05,37.844),(-122.0485,37.817),(-122.0483,37.813),(-122.0482,37.811)] | Oakland + I- 880 | [(-122.0978,37.528),(-122.096,37.496),(-122.0931,37.453),(-122.09277,37.4496),(-122.090189,37.41442),(-122.0896,37.405),(-122.085,37.34)] | Oakland + I- 880 | [(-122.1755,37.185),(-122.1747,37.178),(-122.1742,37.173),(-122.1692,37.126),(-122.167792,37.11594),(-122.16757,37.11435),(-122.1671,37.111),(-122.1655,37.1),(-122.165169,37.09811),(-122.1641,37.092),(-122.1596,37.061),(-122.158381,37.05275),(-122.155991,37.03657),(-122.1531,37.017),(-122.1478,37.98),(-122.1407,37.932),(-122.1394,37.924),(-122.1389,37.92),(-122.1376,37.91)] | Oakland + I- 880 Ramp | [(-122.059,37.982),(-122.0577,37.984),(-122.0612,37.003)] | Oakland + I- 880 Ramp | [(-122.0618,37.011),(-122.0631,37.982),(-122.0585,37.967)] | Oakland + Kaiser Dr | [(-122.067163,37.47821),(-122.060402,37.51961)] | Oakland + La Playa Dr | [(-122.1039,37.545),(-122.101,37.493)] | Oakland + Locust St | [(-122.1606,37.007),(-122.1593,37.987)] | Oakland + Magnolia St | [(-122.0971,37.5),(-122.0962,37.484)] | Oakland + Mattos Dr | [(-122.0005,37.502),(-122.000898,37.49683)] | Oakland + Maubert Ave | [(-122.1114,37.009),(-122.1096,37.995)] | Oakland + McClure Ave | [(-122.1431,37.001),(-122.1436,37.998)] | Oakland + National Ave | [(-122.1192,37.5),(-122.1281,37.489)] | Oakland + Portsmouth Ave | [(-122.1064,37.315),(-122.1064,37.308)] | Oakland + Railroad Ave | [(-122.0245,37.013),(-122.0234,37.003),(-122.0223,37.993)] | Oakland + Ranspot Dr | [(-122.0972,37.999),(-122.0959,37)] | Oakland + Redwood Road | [(-122.1493,37.98),(-122.1437,37.001)] | Oakland + Santa Maria Ave | [(-122.0773,37),(-122.0773,37.98)] | Oakland + Skyline Blvd | [(-122.1738,37.01),(-122.1714,37.996)] | Oakland + Skyline Dr | [(-122.0277,37.5),(-122.0284,37.498)] | Oakland + Sp Railroad | [(-122.0734,37.001),(-122.0734,37.997)] | Oakland + Sp Railroad | [(-122.137792,37.003),(-122.1365,37.992),(-122.131257,37.94612)] | Oakland + Sp Railroad | [(-122.1947,37.497),(-122.193328,37.4848)] | Oakland + State Hwy 92 | [(-122.1085,37.326),(-122.1095,37.322),(-122.1111,37.316),(-122.1119,37.313),(-122.1125,37.311),(-122.1131,37.308),(-122.1167,37.292),(-122.1187,37.285),(-122.12,37.28)] | Oakland + State Hwy 92 Ramp | [(-122.1086,37.321),(-122.1089,37.315),(-122.1111,37.316)] | Oakland + Western Pacific Railroad Spur | [(-122.0394,37.018),(-122.0394,37.961)] | Oakland + Willimet Way | [(-122.0964,37.517),(-122.0949,37.493)] | Oakland + Wisconsin St | [(-122.1994,37.017),(-122.1975,37.998),(-122.1971,37.994)] | Oakland + 100th Ave | [(-122.1657,37.429),(-122.1647,37.432)] | Oakland + 107th Ave | [(-122.1555,37.403),(-122.1531,37.41)] | Oakland + 85th Ave | [(-122.1877,37.466),(-122.186,37.476)] | Oakland + 89th Ave | [(-122.1822,37.459),(-122.1803,37.471)] | Oakland + 98th Ave | [(-122.1568,37.498),(-122.1558,37.502)] | Oakland + 98th Ave | [(-122.1693,37.438),(-122.1682,37.444)] | Oakland + Allen Ct | [(-122.0131,37.602),(-122.0117,37.597)] | Berkeley + Alvarado Niles Road | [(-122.0325,37.903),(-122.0316,37.9)] | Berkeley + Arizona St | [(-122.0381,37.901),(-122.0367,37.898)] | Berkeley + Avenue 134th | [(-122.1823,37.002),(-122.1851,37.992)] | Berkeley + Avenue 140th | [(-122.1656,37.003),(-122.1691,37.988)] | Berkeley + Broadway | [(-122.2409,37.586),(-122.2395,37.601)] | Berkeley + Buckingham Blvd | [(-122.2231,37.59),(-122.2214,37.606)] | Berkeley + Butterfield Dr | [(-122.0838,37.002),(-122.0834,37.987)] | Berkeley + California St | [(-122.2032,37.005),(-122.2016,37.996)] | Berkeley + Campus Dr | [(-122.1704,37.905),(-122.1678,37.868),(-122.1671,37.865)] | Berkeley + Carson St | [(-122.1846,37.9),(-122.1843,37.901)] | Berkeley + Central Ave | [(-122.2343,37.602),(-122.2331,37.595)] | Berkeley + Champion St | [(-122.214,37.991),(-122.2147,37.002)] | Berkeley + Claremont Pl | [(-122.0542,37.995),(-122.0542,37.008)] | Berkeley + Coliseum Way | [(-122.2113,37.626),(-122.2085,37.592),(-122.2063,37.568)] | Berkeley + Cornell Ave | [(-122.2956,37.925),(-122.2949,37.906),(-122.2939,37.875)] | Berkeley + Creston Road | [(-122.2639,37.002),(-122.2613,37.986),(-122.2602,37.978),(-122.2598,37.973)] | Berkeley + Crow Canyon Creek | [(-122.043,37.905),(-122.0368,37.71)] | Berkeley + Cull Creek | [(-122.0624,37.875),(-122.0582,37.527)] | Berkeley + Decoto Road | [(-122.0159,37.006),(-122.016,37.002),(-122.0164,37.993)] | Berkeley + Deering St | [(-122.2146,37.904),(-122.2126,37.897)] | Berkeley + Dimond Ave | [(-122.2167,37.994),(-122.2162,37.006)] | Berkeley + Donna Way | [(-122.1333,37.606),(-122.1316,37.599)] | Berkeley + Eden Creek | [(-122.022037,37.00675),(-122.0221,37.998)] | Berkeley + Euclid Ave | [(-122.2671,37.009),(-122.2666,37.987)] | Berkeley + Foothill Blvd | [(-122.2414,37.9),(-122.2403,37.893)] | Berkeley + Fountain St | [(-122.2306,37.593),(-122.2293,37.605)] | Berkeley + Grizzly Peak Blvd | [(-122.2213,37.638),(-122.2127,37.581)] | Berkeley + Grove Way | [(-122.0643,37.884),(-122.062679,37.89162),(-122.061796,37.89578),(-122.0609,37.9)] | Berkeley + Herrier St | [(-122.1943,37.006),(-122.1936,37.998)] | Berkeley + Hesperian Blvd | [(-122.1132,37.6),(-122.1123,37.586)] | Berkeley + I- 580 | [(-122.1108,37.023),(-122.1101,37.02),(-122.108103,37.00764),(-122.108,37.007),(-122.1069,37.998),(-122.1064,37.994),(-122.1053,37.982),(-122.1048,37.977),(-122.1032,37.958),(-122.1026,37.953),(-122.1013,37.938),(-122.0989,37.911),(-122.0984,37.91),(-122.098,37.908)] | Berkeley + I- 580 | [(-122.1543,37.703),(-122.1535,37.694),(-122.1512,37.655),(-122.1475,37.603),(-122.1468,37.583),(-122.1472,37.569),(-122.149044,37.54874),(-122.1493,37.546),(-122.1501,37.532),(-122.1506,37.509),(-122.1495,37.482),(-122.1487,37.467),(-122.1477,37.447),(-122.1414,37.383),(-122.1404,37.376),(-122.1398,37.372),(-122.139,37.356),(-122.1388,37.353),(-122.1385,37.34),(-122.1382,37.33),(-122.1378,37.316)] | Berkeley + I- 580 | [(-122.2197,37.99),(-122.22,37.99),(-122.222092,37.99523),(-122.2232,37.998),(-122.224146,37.99963),(-122.2261,37.003),(-122.2278,37.007),(-122.2302,37.026),(-122.2323,37.043),(-122.2344,37.059),(-122.235405,37.06427),(-122.2365,37.07)] | Berkeley + I- 580 Ramp | [(-122.093241,37.90351),(-122.09364,37.89634),(-122.093788,37.89212)] | Berkeley + I- 580 Ramp | [(-122.0934,37.896),(-122.09257,37.89961),(-122.0911,37.906)] | Berkeley + I- 580 Ramp | [(-122.0941,37.897),(-122.0943,37.902)] | Berkeley + I- 580 Ramp | [(-122.096,37.888),(-122.0962,37.891),(-122.0964,37.9)] | Berkeley + I- 580 Ramp | [(-122.101,37.898),(-122.1005,37.902),(-122.0989,37.911)] | Berkeley + I- 580 Ramp | [(-122.1086,37.003),(-122.1068,37.993),(-122.1066,37.992),(-122.1053,37.982)] | Berkeley + I- 880 | [(-122.0375,37.632),(-122.0359,37.619),(-122.0358,37.616),(-122.034514,37.60409),(-122.031876,37.57965),(-122.031193,37.57332),(-122.03016,37.56375),(-122.02943,37.55698),(-122.028689,37.54929),(-122.027833,37.53908),(-122.025979,37.51698),(-122.0238,37.491)] | Berkeley + I- 880 | [(-122.0612,37.003),(-122.0604,37.991),(-122.0596,37.982),(-122.0585,37.967),(-122.0583,37.961),(-122.0553,37.918),(-122.053635,37.89475),(-122.050759,37.8546),(-122.05,37.844),(-122.0485,37.817),(-122.0483,37.813),(-122.0482,37.811)] | Berkeley + I- 880 | [(-122.1365,37.902),(-122.1358,37.898),(-122.1333,37.881),(-122.1323,37.874),(-122.1311,37.866),(-122.1308,37.865),(-122.1307,37.864),(-122.1289,37.851),(-122.1277,37.843),(-122.1264,37.834),(-122.1231,37.812),(-122.1165,37.766),(-122.1104,37.72),(-122.109695,37.71094),(-122.109,37.702),(-122.108312,37.69168),(-122.1076,37.681)] | Berkeley + I- 880 | [(-122.1755,37.185),(-122.1747,37.178),(-122.1742,37.173),(-122.1692,37.126),(-122.167792,37.11594),(-122.16757,37.11435),(-122.1671,37.111),(-122.1655,37.1),(-122.165169,37.09811),(-122.1641,37.092),(-122.1596,37.061),(-122.158381,37.05275),(-122.155991,37.03657),(-122.1531,37.017),(-122.1478,37.98),(-122.1407,37.932),(-122.1394,37.924),(-122.1389,37.92),(-122.1376,37.91)] | Berkeley + I- 880 | [(-122.2214,37.711),(-122.2202,37.699),(-122.2199,37.695),(-122.219,37.682),(-122.2184,37.672),(-122.2173,37.652),(-122.2159,37.638),(-122.2144,37.616),(-122.2138,37.612),(-122.2135,37.609),(-122.212,37.592),(-122.2116,37.586),(-122.2111,37.581)] | Berkeley + I- 880 | [(-122.2707,37.975),(-122.2693,37.972),(-122.2681,37.966),(-122.267,37.962),(-122.2659,37.957),(-122.2648,37.952),(-122.2636,37.946),(-122.2625,37.935),(-122.2617,37.927),(-122.2607,37.921),(-122.2593,37.916),(-122.258,37.911),(-122.2536,37.898),(-122.2432,37.858),(-122.2408,37.845),(-122.2386,37.827),(-122.2374,37.811)] | Berkeley + I- 880 Ramp | [(-122.059,37.982),(-122.0577,37.984),(-122.0612,37.003)] | Berkeley + I- 880 Ramp | [(-122.0618,37.011),(-122.0631,37.982),(-122.0585,37.967)] | Berkeley + I- 880 Ramp | [(-122.1029,37.61),(-122.1013,37.587),(-122.0999,37.569)] | Berkeley + I- 880 Ramp | [(-122.1379,37.891),(-122.1383,37.897),(-122.1377,37.902)] | Berkeley + I- 880 Ramp | [(-122.1379,37.931),(-122.137597,37.92736),(-122.1374,37.925),(-122.1373,37.924),(-122.1369,37.914),(-122.1358,37.905),(-122.1365,37.908),(-122.1358,37.898)] | Berkeley + I- 880 Ramp | [(-122.2536,37.898),(-122.254,37.902)] | Berkeley + Jackson St | [(-122.0845,37.6),(-122.0842,37.606)] | Berkeley + Joyce St | [(-122.0792,37.604),(-122.0774,37.581)] | Berkeley + Keeler Ave | [(-122.2578,37.906),(-122.2579,37.899)] | Berkeley + Laguna Ave | [(-122.2099,37.989),(-122.2089,37)] | Berkeley + Lakehurst Cir | [(-122.284729,37.89025),(-122.286096,37.90364)] | Berkeley + Lakeshore Ave | [(-122.2586,37.99),(-122.2556,37.006)] | Berkeley + Linden St | [(-122.2867,37.998),(-122.2864,37.008)] | Berkeley + Locust St | [(-122.1606,37.007),(-122.1593,37.987)] | Berkeley + Marin Ave | [(-122.2741,37.894),(-122.272,37.901)] | Berkeley + Martin Luther King Jr Way | [(-122.2712,37.608),(-122.2711,37.599)] | Berkeley + Maubert Ave | [(-122.1114,37.009),(-122.1096,37.995)] | Berkeley + McClure Ave | [(-122.1431,37.001),(-122.1436,37.998)] | Berkeley + Miller Road | [(-122.0902,37.645),(-122.0865,37.545)] | Berkeley + Mission Blvd | [(-122.0006,37.896),(-121.9989,37.88)] | Berkeley + Oakland Inner Harbor | [(-122.2625,37.913),(-122.260016,37.89484)] | Berkeley + Oneil Ave | [(-122.076754,37.62476),(-122.0745,37.595)] | Berkeley + Parkridge Dr | [(-122.1438,37.884),(-122.1428,37.9)] | Berkeley + Parkside Dr | [(-122.0475,37.603),(-122.0443,37.596)] | Berkeley + Paseo Padre Pkwy | [(-122.0021,37.639),(-121.996,37.628)] | Berkeley + Pearl St | [(-122.2383,37.594),(-122.2366,37.615)] | Berkeley + Railroad Ave | [(-122.0245,37.013),(-122.0234,37.003),(-122.0223,37.993)] | Berkeley + Ranspot Dr | [(-122.0972,37.999),(-122.0959,37)] | Berkeley + Redding St | [(-122.1978,37.901),(-122.1975,37.895)] | Berkeley + Redwood Road | [(-122.1493,37.98),(-122.1437,37.001)] | Berkeley + Roca Dr | [(-122.0335,37.609),(-122.0314,37.599)] | Berkeley + Sacramento St | [(-122.2799,37.606),(-122.2797,37.597)] | Berkeley + Saddle Brook Dr | [(-122.1478,37.909),(-122.1454,37.904),(-122.1451,37.888)] | Berkeley + San Andreas Dr | [(-122.0609,37.9),(-122.0614,37.895)] | Berkeley + Santa Maria Ave | [(-122.0773,37),(-122.0773,37.98)] | Berkeley + Shattuck Ave | [(-122.2686,37.904),(-122.2686,37.897)] | Berkeley + Shoreline Dr | [(-122.2657,37.603),(-122.2648,37.6)] | Berkeley + Skyline Blvd | [(-122.1738,37.01),(-122.1714,37.996)] | Berkeley + Skywest Dr | [(-122.1161,37.62),(-122.1123,37.586)] | Berkeley + Sp Railroad | [(-122.0734,37.001),(-122.0734,37.997)] | Berkeley + Sp Railroad | [(-122.0914,37.601),(-122.087,37.56),(-122.086408,37.5551)] | Berkeley + Sp Railroad | [(-122.137792,37.003),(-122.1365,37.992),(-122.131257,37.94612)] | Berkeley + State Hwy 123 | [(-122.3004,37.986),(-122.2998,37.969),(-122.2995,37.962),(-122.2992,37.952),(-122.299,37.942),(-122.2987,37.935),(-122.2984,37.924),(-122.2982,37.92),(-122.2976,37.904),(-122.297,37.88),(-122.2966,37.869),(-122.2959,37.848),(-122.2961,37.843)] | Berkeley + State Hwy 13 | [(-122.1797,37.943),(-122.179871,37.91849),(-122.18,37.9),(-122.179023,37.86615),(-122.1787,37.862),(-122.1781,37.851),(-122.1777,37.845),(-122.1773,37.839),(-122.177,37.833)] | Berkeley + State Hwy 238 | ((-122.098,37.908),(-122.0983,37.907),(-122.099,37.905),(-122.101,37.898),(-122.101535,37.89711),(-122.103173,37.89438),(-122.1046,37.892),(-122.106,37.89)) | Berkeley + State Hwy 238 Ramp | [(-122.1288,37.9),(-122.1293,37.895),(-122.1296,37.906)] | Berkeley + Stuart St | [(-122.2518,37.6),(-122.2507,37.601),(-122.2491,37.606)] | Berkeley + Tupelo Ter | [(-122.059087,37.6113),(-122.057021,37.59942)] | Berkeley + West Loop Road | [(-122.0576,37.604),(-122.0602,37.586)] | Berkeley + Western Pacific Railroad Spur | [(-122.0394,37.018),(-122.0394,37.961)] | Berkeley + Wisconsin St | [(-122.1994,37.017),(-122.1975,37.998),(-122.1971,37.994)] | Berkeley + Wp Railroad | [(-122.254,37.902),(-122.2506,37.891)] | Berkeley + 19th Ave | [(-122.2366,37.897),(-122.2359,37.905)] | Berkeley + 5th St | [(-122.296,37.615),(-122.2953,37.598)] | Berkeley + 82nd Ave | [(-122.1695,37.596),(-122.1681,37.603)] | Berkeley + Ada St | [(-122.2487,37.398),(-122.2496,37.401)] | Lafayette + California St | [(-122.2032,37.005),(-122.2016,37.996)] | Lafayette + Capricorn Ave | [(-122.2176,37.404),(-122.2164,37.384)] | Lafayette + Chambers Dr | [(-122.2004,37.352),(-122.1972,37.368)] | Lafayette + Chambers Lane | [(-122.2001,37.359),(-122.1975,37.371)] | Lafayette + Champion St | [(-122.214,37.991),(-122.2147,37.002)] | Lafayette + Coolidge Ave | [(-122.2007,37.058),(-122.1992,37.06)] | Lafayette + Creston Road | [(-122.2639,37.002),(-122.2613,37.986),(-122.2602,37.978),(-122.2598,37.973)] | Lafayette + Dimond Ave | [(-122.2167,37.994),(-122.2162,37.006)] | Lafayette + Edgewater Dr | [(-122.201,37.379),(-122.2042,37.41)] | Lafayette + Euclid Ave | [(-122.2671,37.009),(-122.2666,37.987)] | Lafayette + Heartwood Dr | [(-122.2006,37.341),(-122.1992,37.338)] | Lafayette + Hollis St | [(-122.2885,37.397),(-122.289,37.414)] | Lafayette + I- 580 | [(-122.2197,37.99),(-122.22,37.99),(-122.222092,37.99523),(-122.2232,37.998),(-122.224146,37.99963),(-122.2261,37.003),(-122.2278,37.007),(-122.2302,37.026),(-122.2323,37.043),(-122.2344,37.059),(-122.235405,37.06427),(-122.2365,37.07)] | Lafayette + I- 80 Ramp | [(-122.2962,37.413),(-122.2959,37.382),(-122.2951,37.372)] | Lafayette + I- 880 Ramp | [(-122.2771,37.002),(-122.278,37)] | Lafayette + Indian Way | [(-122.2066,37.398),(-122.2045,37.411)] | Lafayette + Laguna Ave | [(-122.2099,37.989),(-122.2089,37)] | Lafayette + Lakeshore Ave | [(-122.2586,37.99),(-122.2556,37.006)] | Lafayette + Linden St | [(-122.2867,37.998),(-122.2864,37.008)] | Lafayette + Mandalay Road | [(-122.2322,37.397),(-122.2321,37.403)] | Lafayette + Proctor Ave | [(-122.2267,37.406),(-122.2251,37.386)] | Lafayette + Sheridan Road | [(-122.2279,37.425),(-122.2253,37.411),(-122.2223,37.377)] | Lafayette + State Hwy 13 | [(-122.2049,37.2),(-122.20328,37.17975),(-122.1989,37.125),(-122.198078,37.11641),(-122.1975,37.11)] | Lafayette + State Hwy 13 Ramp | [(-122.2244,37.427),(-122.223,37.414),(-122.2214,37.396),(-122.2213,37.388)] | Lafayette + State Hwy 24 | [(-122.2674,37.246),(-122.2673,37.248),(-122.267,37.261),(-122.2668,37.271),(-122.2663,37.298),(-122.2659,37.315),(-122.2655,37.336),(-122.265007,37.35882),(-122.264443,37.37286),(-122.2641,37.381),(-122.2638,37.388),(-122.2631,37.396),(-122.2617,37.405),(-122.2615,37.407),(-122.2605,37.412)] | Lafayette + Taurus Ave | [(-122.2159,37.416),(-122.2128,37.389)] | Lafayette + 5th St | [(-122.278,37),(-122.2792,37.005),(-122.2803,37.009)] | Lafayette + 98th Ave | [(-122.2001,37.258),(-122.1974,37.27)] | Lafayette (282 rows) -QUERY: SELECT name, #thepath FROM iexit ORDER BY 1, 2; -name |?column? -----------------------------------+-------- -I- 580 | 2 -I- 580 | 2 -I- 580 | 2 -I- 580 | 2 -I- 580 | 2 -I- 580 | 2 -I- 580 | 2 -I- 580 | 2 -I- 580 | 2 -I- 580 | 2 -I- 580 | 2 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 3 -I- 580 | 4 -I- 580 | 4 -I- 580 | 4 -I- 580 | 4 -I- 580 | 5 -I- 580 | 5 -I- 580 | 5 -I- 580 | 5 -I- 580 | 5 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 6 -I- 580 | 7 -I- 580 | 7 -I- 580 | 7 -I- 580 | 7 -I- 580 | 7 -I- 580 | 7 -I- 580 | 7 -I- 580 | 8 -I- 580 | 8 -I- 580 | 8 -I- 580 | 8 -I- 580 | 8 -I- 580 | 8 -I- 580 | 8 -I- 580 | 8 -I- 580 | 9 -I- 580 | 9 -I- 580 | 9 -I- 580 | 9 -I- 580 | 9 -I- 580 | 12 -I- 580 | 12 -I- 580 | 12 -I- 580 | 12 -I- 580 | 12 -I- 580 | 12 -I- 580 | 12 -I- 580 | 12 -I- 580 | 12 -I- 580 | 12 -I- 580 | 13 -I- 580 | 13 -I- 580 | 13 -I- 580 | 13 -I- 580 | 13 -I- 580 | 13 -I- 580 | 14 -I- 580 | 14 -I- 580 | 14 -I- 580 | 14 -I- 580 | 14 -I- 580 | 14 -I- 580 | 14 -I- 580 | 14 -I- 580 | 18 -I- 580 | 18 -I- 580 | 18 -I- 580 | 18 -I- 580 | 18 -I- 580 | 18 -I- 580 | 21 -I- 580 | 21 -I- 580 | 21 -I- 580 | 21 -I- 580 | 21 -I- 580 | 21 -I- 580 | 21 -I- 580 | 21 -I- 580 | 21 -I- 580 | 21 -I- 580 | 22 -I- 580 | 22 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 2 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 3 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 4 -I- 580 Ramp| 5 -I- 580 Ramp| 5 -I- 580 Ramp| 5 -I- 580 Ramp| 5 -I- 580 Ramp| 5 -I- 580 Ramp| 5 -I- 580 Ramp| 5 -I- 580 Ramp| 5 -I- 580 Ramp| 5 -I- 580 Ramp| 5 -I- 580 Ramp| 5 -I- 580 Ramp| 5 -I- 580 Ramp| 5 -I- 580 Ramp| 5 -I- 580 Ramp| 6 -I- 580 Ramp| 6 -I- 580 Ramp| 6 -I- 580 Ramp| 7 -I- 580 Ramp| 8 -I- 580 Ramp| 8 -I- 580 Ramp| 8 -I- 580 Ramp| 8 -I- 580 Ramp| 8 -I- 580 Ramp| 8 -I- 580/I-680 Ramp| 2 -I- 580/I-680 Ramp| 2 -I- 580/I-680 Ramp| 2 -I- 580/I-680 Ramp| 2 -I- 580/I-680 Ramp| 2 -I- 580/I-680 Ramp| 2 -I- 580/I-680 Ramp| 4 -I- 580/I-680 Ramp| 4 -I- 580/I-680 Ramp| 4 -I- 580/I-680 Ramp| 4 -I- 580/I-680 Ramp| 5 -I- 580/I-680 Ramp| 6 -I- 580/I-680 Ramp| 6 -I- 580/I-680 Ramp| 6 -I- 680 | 2 -I- 680 | 2 -I- 680 | 2 -I- 680 | 2 -I- 680 | 2 -I- 680 | 2 -I- 680 | 2 -I- 680 | 3 -I- 680 | 3 -I- 680 | 3 -I- 680 | 4 -I- 680 | 4 -I- 680 | 4 -I- 680 | 5 -I- 680 | 5 -I- 680 | 5 -I- 680 | 7 -I- 680 | 7 -I- 680 | 7 -I- 680 | 7 -I- 680 | 8 -I- 680 | 8 -I- 680 | 8 -I- 680 | 8 -I- 680 | 10 -I- 680 | 10 -I- 680 | 10 -I- 680 | 10 -I- 680 | 10 -I- 680 | 10 -I- 680 | 10 -I- 680 | 16 -I- 680 | 16 -I- 680 | 16 -I- 680 | 16 -I- 680 | 16 -I- 680 | 16 -I- 680 | 16 -I- 680 | 16 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 2 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 3 -I- 680 Ramp| 4 -I- 680 Ramp| 4 -I- 680 Ramp| 4 -I- 680 Ramp| 5 -I- 680 Ramp| 5 -I- 680 Ramp| 5 -I- 680 Ramp| 5 -I- 680 Ramp| 5 -I- 680 Ramp| 5 -I- 680 Ramp| 6 -I- 680 Ramp| 6 -I- 680 Ramp| 6 -I- 680 Ramp| 6 -I- 680 Ramp| 7 -I- 680 Ramp| 7 -I- 680 Ramp| 7 -I- 680 Ramp| 7 -I- 680 Ramp| 8 -I- 680 Ramp| 8 -I- 680 Ramp| 8 -I- 680 Ramp| 8 -I- 80 | 2 -I- 80 | 2 -I- 80 | 2 -I- 80 | 2 -I- 80 | 2 -I- 80 | 2 -I- 80 | 2 -I- 80 | 2 -I- 80 | 2 -I- 80 | 2 -I- 80 | 2 -I- 80 | 2 -I- 80 | 2 -I- 80 | 2 -I- 80 | 3 -I- 80 | 3 -I- 80 | 3 -I- 80 | 4 -I- 80 | 4 -I- 80 | 4 -I- 80 | 4 -I- 80 | 4 -I- 80 | 5 -I- 80 | 5 -I- 80 | 5 -I- 80 | 5 -I- 80 | 5 -I- 80 | 5 -I- 80 | 5 -I- 80 | 5 -I- 80 | 5 -I- 80 | 11 -I- 80 | 11 -I- 80 | 11 -I- 80 | 11 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 2 -I- 80 Ramp| 3 -I- 80 Ramp| 3 -I- 80 Ramp| 3 -I- 80 Ramp| 3 -I- 80 Ramp| 3 -I- 80 Ramp| 3 -I- 80 Ramp| 3 -I- 80 Ramp| 3 -I- 80 Ramp| 3 -I- 80 Ramp| 4 -I- 80 Ramp| 4 -I- 80 Ramp| 4 -I- 80 Ramp| 4 -I- 80 Ramp| 5 -I- 80 Ramp| 5 -I- 80 Ramp| 5 -I- 80 Ramp| 5 -I- 80 Ramp| 5 -I- 80 Ramp| 5 -I- 80 Ramp| 5 -I- 80 Ramp| 7 -I- 80 Ramp| 7 -I- 80 Ramp| 7 -I- 80 Ramp| 7 -I- 880 | 2 -I- 880 | 2 -I- 880 | 2 -I- 880 | 2 -I- 880 | 2 -I- 880 | 5 -I- 880 | 5 -I- 880 | 5 -I- 880 | 5 -I- 880 | 5 -I- 880 | 5 -I- 880 | 6 -I- 880 | 6 -I- 880 | 6 -I- 880 | 6 -I- 880 | 6 -I- 880 | 6 -I- 880 | 6 -I- 880 | 6 -I- 880 | 6 -I- 880 | 6 -I- 880 | 6 -I- 880 | 6 -I- 880 | 6 -I- 880 | 7 -I- 880 | 7 -I- 880 | 7 -I- 880 | 7 -I- 880 | 7 -I- 880 | 7 -I- 880 | 7 -I- 880 | 9 -I- 880 | 9 -I- 880 | 9 -I- 880 | 9 -I- 880 | 9 -I- 880 | 9 -I- 880 | 9 -I- 880 | 10 -I- 880 | 10 -I- 880 | 10 -I- 880 | 10 -I- 880 | 10 -I- 880 | 10 -I- 880 | 10 -I- 880 | 10 -I- 880 | 10 -I- 880 | 10 -I- 880 | 10 -I- 880 | 10 -I- 880 | 12 -I- 880 | 12 -I- 880 | 12 -I- 880 | 12 -I- 880 | 12 -I- 880 | 12 -I- 880 | 12 -I- 880 | 12 -I- 880 | 12 -I- 880 | 12 -I- 880 | 12 -I- 880 | 13 -I- 880 | 13 -I- 880 | 13 -I- 880 | 13 -I- 880 | 13 -I- 880 | 13 -I- 880 | 13 -I- 880 | 13 -I- 880 | 13 -I- 880 | 13 -I- 880 | 13 -I- 880 | 13 -I- 880 | 14 -I- 880 | 14 -I- 880 | 14 -I- 880 | 14 -I- 880 | 14 -I- 880 | 14 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 17 -I- 880 | 19 -I- 880 | 19 -I- 880 | 19 -I- 880 | 19 -I- 880 | 19 -I- 880 | 19 -I- 880 | 19 -I- 880 | 19 -I- 880 | 19 -I- 880 | 19 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 2 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 3 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 4 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 5 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 6 -I- 880 Ramp| 8 -I- 880 Ramp| 8 -I- 880 Ramp| 8 -I- 980 | 2 -I- 980 | 2 -I- 980 | 2 -I- 980 | 2 -I- 980 | 2 -I- 980 | 2 -I- 980 | 2 -I- 980 | 2 -I- 980 | 3 -I- 980 | 3 -I- 980 | 3 -I- 980 | 3 -I- 980 | 3 -I- 980 | 3 -I- 980 | 3 -I- 980 | 3 -I- 980 | 3 -I- 980 | 4 -I- 980 | 4 -I- 980 | 5 -I- 980 | 5 -I- 980 | 7 -I- 980 | 7 -I- 980 | 7 -I- 980 | 7 -I- 980 | 12 -I- 980 Ramp| 3 -I- 980 Ramp| 3 -I- 980 Ramp| 3 -I- 980 Ramp| 7 +SELECT name, #thepath FROM iexit ORDER BY 1, 2; + name | ?column? +------------------------------------+---------- + I- 580 | 2 + I- 580 | 2 + I- 580 | 2 + I- 580 | 2 + I- 580 | 2 + I- 580 | 2 + I- 580 | 2 + I- 580 | 2 + I- 580 | 2 + I- 580 | 2 + I- 580 | 2 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 3 + I- 580 | 4 + I- 580 | 4 + I- 580 | 4 + I- 580 | 4 + I- 580 | 5 + I- 580 | 5 + I- 580 | 5 + I- 580 | 5 + I- 580 | 5 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 6 + I- 580 | 7 + I- 580 | 7 + I- 580 | 7 + I- 580 | 7 + I- 580 | 7 + I- 580 | 7 + I- 580 | 7 + I- 580 | 8 + I- 580 | 8 + I- 580 | 8 + I- 580 | 8 + I- 580 | 8 + I- 580 | 8 + I- 580 | 8 + I- 580 | 8 + I- 580 | 9 + I- 580 | 9 + I- 580 | 9 + I- 580 | 9 + I- 580 | 9 + I- 580 | 12 + I- 580 | 12 + I- 580 | 12 + I- 580 | 12 + I- 580 | 12 + I- 580 | 12 + I- 580 | 12 + I- 580 | 12 + I- 580 | 12 + I- 580 | 12 + I- 580 | 13 + I- 580 | 13 + I- 580 | 13 + I- 580 | 13 + I- 580 | 13 + I- 580 | 13 + I- 580 | 14 + I- 580 | 14 + I- 580 | 14 + I- 580 | 14 + I- 580 | 14 + I- 580 | 14 + I- 580 | 14 + I- 580 | 14 + I- 580 | 18 + I- 580 | 18 + I- 580 | 18 + I- 580 | 18 + I- 580 | 18 + I- 580 | 18 + I- 580 | 21 + I- 580 | 21 + I- 580 | 21 + I- 580 | 21 + I- 580 | 21 + I- 580 | 21 + I- 580 | 21 + I- 580 | 21 + I- 580 | 21 + I- 580 | 21 + I- 580 | 22 + I- 580 | 22 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 2 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 3 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 4 + I- 580 Ramp | 5 + I- 580 Ramp | 5 + I- 580 Ramp | 5 + I- 580 Ramp | 5 + I- 580 Ramp | 5 + I- 580 Ramp | 5 + I- 580 Ramp | 5 + I- 580 Ramp | 5 + I- 580 Ramp | 5 + I- 580 Ramp | 5 + I- 580 Ramp | 5 + I- 580 Ramp | 5 + I- 580 Ramp | 5 + I- 580 Ramp | 5 + I- 580 Ramp | 6 + I- 580 Ramp | 6 + I- 580 Ramp | 6 + I- 580 Ramp | 7 + I- 580 Ramp | 8 + I- 580 Ramp | 8 + I- 580 Ramp | 8 + I- 580 Ramp | 8 + I- 580 Ramp | 8 + I- 580 Ramp | 8 + I- 580/I-680 Ramp | 2 + I- 580/I-680 Ramp | 2 + I- 580/I-680 Ramp | 2 + I- 580/I-680 Ramp | 2 + I- 580/I-680 Ramp | 2 + I- 580/I-680 Ramp | 2 + I- 580/I-680 Ramp | 4 + I- 580/I-680 Ramp | 4 + I- 580/I-680 Ramp | 4 + I- 580/I-680 Ramp | 4 + I- 580/I-680 Ramp | 5 + I- 580/I-680 Ramp | 6 + I- 580/I-680 Ramp | 6 + I- 580/I-680 Ramp | 6 + I- 680 | 2 + I- 680 | 2 + I- 680 | 2 + I- 680 | 2 + I- 680 | 2 + I- 680 | 2 + I- 680 | 2 + I- 680 | 3 + I- 680 | 3 + I- 680 | 3 + I- 680 | 4 + I- 680 | 4 + I- 680 | 4 + I- 680 | 5 + I- 680 | 5 + I- 680 | 5 + I- 680 | 7 + I- 680 | 7 + I- 680 | 7 + I- 680 | 7 + I- 680 | 8 + I- 680 | 8 + I- 680 | 8 + I- 680 | 8 + I- 680 | 10 + I- 680 | 10 + I- 680 | 10 + I- 680 | 10 + I- 680 | 10 + I- 680 | 10 + I- 680 | 10 + I- 680 | 16 + I- 680 | 16 + I- 680 | 16 + I- 680 | 16 + I- 680 | 16 + I- 680 | 16 + I- 680 | 16 + I- 680 | 16 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 2 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 3 + I- 680 Ramp | 4 + I- 680 Ramp | 4 + I- 680 Ramp | 4 + I- 680 Ramp | 5 + I- 680 Ramp | 5 + I- 680 Ramp | 5 + I- 680 Ramp | 5 + I- 680 Ramp | 5 + I- 680 Ramp | 5 + I- 680 Ramp | 6 + I- 680 Ramp | 6 + I- 680 Ramp | 6 + I- 680 Ramp | 6 + I- 680 Ramp | 7 + I- 680 Ramp | 7 + I- 680 Ramp | 7 + I- 680 Ramp | 7 + I- 680 Ramp | 8 + I- 680 Ramp | 8 + I- 680 Ramp | 8 + I- 680 Ramp | 8 + I- 80 | 2 + I- 80 | 2 + I- 80 | 2 + I- 80 | 2 + I- 80 | 2 + I- 80 | 2 + I- 80 | 2 + I- 80 | 2 + I- 80 | 2 + I- 80 | 2 + I- 80 | 2 + I- 80 | 2 + I- 80 | 2 + I- 80 | 2 + I- 80 | 3 + I- 80 | 3 + I- 80 | 3 + I- 80 | 4 + I- 80 | 4 + I- 80 | 4 + I- 80 | 4 + I- 80 | 4 + I- 80 | 5 + I- 80 | 5 + I- 80 | 5 + I- 80 | 5 + I- 80 | 5 + I- 80 | 5 + I- 80 | 5 + I- 80 | 5 + I- 80 | 5 + I- 80 | 11 + I- 80 | 11 + I- 80 | 11 + I- 80 | 11 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 2 + I- 80 Ramp | 3 + I- 80 Ramp | 3 + I- 80 Ramp | 3 + I- 80 Ramp | 3 + I- 80 Ramp | 3 + I- 80 Ramp | 3 + I- 80 Ramp | 3 + I- 80 Ramp | 3 + I- 80 Ramp | 3 + I- 80 Ramp | 4 + I- 80 Ramp | 4 + I- 80 Ramp | 4 + I- 80 Ramp | 4 + I- 80 Ramp | 5 + I- 80 Ramp | 5 + I- 80 Ramp | 5 + I- 80 Ramp | 5 + I- 80 Ramp | 5 + I- 80 Ramp | 5 + I- 80 Ramp | 5 + I- 80 Ramp | 7 + I- 80 Ramp | 7 + I- 80 Ramp | 7 + I- 80 Ramp | 7 + I- 880 | 2 + I- 880 | 2 + I- 880 | 2 + I- 880 | 2 + I- 880 | 2 + I- 880 | 5 + I- 880 | 5 + I- 880 | 5 + I- 880 | 5 + I- 880 | 5 + I- 880 | 5 + I- 880 | 6 + I- 880 | 6 + I- 880 | 6 + I- 880 | 6 + I- 880 | 6 + I- 880 | 6 + I- 880 | 6 + I- 880 | 6 + I- 880 | 6 + I- 880 | 6 + I- 880 | 6 + I- 880 | 6 + I- 880 | 6 + I- 880 | 7 + I- 880 | 7 + I- 880 | 7 + I- 880 | 7 + I- 880 | 7 + I- 880 | 7 + I- 880 | 7 + I- 880 | 9 + I- 880 | 9 + I- 880 | 9 + I- 880 | 9 + I- 880 | 9 + I- 880 | 9 + I- 880 | 9 + I- 880 | 10 + I- 880 | 10 + I- 880 | 10 + I- 880 | 10 + I- 880 | 10 + I- 880 | 10 + I- 880 | 10 + I- 880 | 10 + I- 880 | 10 + I- 880 | 10 + I- 880 | 10 + I- 880 | 10 + I- 880 | 12 + I- 880 | 12 + I- 880 | 12 + I- 880 | 12 + I- 880 | 12 + I- 880 | 12 + I- 880 | 12 + I- 880 | 12 + I- 880 | 12 + I- 880 | 12 + I- 880 | 12 + I- 880 | 13 + I- 880 | 13 + I- 880 | 13 + I- 880 | 13 + I- 880 | 13 + I- 880 | 13 + I- 880 | 13 + I- 880 | 13 + I- 880 | 13 + I- 880 | 13 + I- 880 | 13 + I- 880 | 13 + I- 880 | 14 + I- 880 | 14 + I- 880 | 14 + I- 880 | 14 + I- 880 | 14 + I- 880 | 14 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 17 + I- 880 | 19 + I- 880 | 19 + I- 880 | 19 + I- 880 | 19 + I- 880 | 19 + I- 880 | 19 + I- 880 | 19 + I- 880 | 19 + I- 880 | 19 + I- 880 | 19 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 2 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 3 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 4 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 5 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 6 + I- 880 Ramp | 8 + I- 880 Ramp | 8 + I- 880 Ramp | 8 + I- 980 | 2 + I- 980 | 2 + I- 980 | 2 + I- 980 | 2 + I- 980 | 2 + I- 980 | 2 + I- 980 | 2 + I- 980 | 2 + I- 980 | 3 + I- 980 | 3 + I- 980 | 3 + I- 980 | 3 + I- 980 | 3 + I- 980 | 3 + I- 980 | 3 + I- 980 | 3 + I- 980 | 3 + I- 980 | 4 + I- 980 | 4 + I- 980 | 5 + I- 980 | 5 + I- 980 | 7 + I- 980 | 7 + I- 980 | 7 + I- 980 | 7 + I- 980 | 12 + I- 980 Ramp | 3 + I- 980 Ramp | 3 + I- 980 Ramp | 3 + I- 980 Ramp | 7 (894 rows) -QUERY: SELECT * FROM toyemp WHERE name = 'sharon'; -name |age|location|annualsal -------+---+--------+--------- -sharon| 25|(15,12) | 12000 +SELECT * FROM toyemp WHERE name = 'sharon'; + name | age | location | annualsal +--------+-----+----------+----------- + sharon | 25 | (15,12) | 12000 (1 row) diff --git a/src/test/regress/expected/temp.out b/src/test/regress/expected/temp.out index c00450470b..7d085de85b 100644 --- a/src/test/regress/expected/temp.out +++ b/src/test/regress/expected/temp.out @@ -1,29 +1,37 @@ -QUERY: CREATE TABLE temptest(col int); -QUERY: CREATE INDEX i_temptest ON temptest(col); -QUERY: CREATE TEMP TABLE temptest(col int); -QUERY: CREATE INDEX i_temptest ON temptest(col); -QUERY: DROP INDEX i_temptest; -QUERY: DROP TABLE temptest; -QUERY: DROP INDEX i_temptest; -QUERY: DROP TABLE temptest; -QUERY: CREATE TABLE temptest(col int); -QUERY: INSERT INTO temptest VALUES (1); -QUERY: CREATE TEMP TABLE temptest(col int); -QUERY: INSERT INTO temptest VALUES (2); -QUERY: SELECT * FROM temptest; -col ---- - 2 +-- +-- TEMP +-- Test temp relations and indexes +-- +-- test temp table/index masking +CREATE TABLE temptest(col int); +CREATE INDEX i_temptest ON temptest(col); +CREATE TEMP TABLE temptest(col int); +CREATE INDEX i_temptest ON temptest(col); +DROP INDEX i_temptest; +DROP TABLE temptest; +DROP INDEX i_temptest; +DROP TABLE temptest; +-- test temp table selects +CREATE TABLE temptest(col int); +INSERT INTO temptest VALUES (1); +CREATE TEMP TABLE temptest(col int); +INSERT INTO temptest VALUES (2); +SELECT * FROM temptest; + col +----- + 2 (1 row) -QUERY: DROP TABLE temptest; -QUERY: SELECT * FROM temptest; -col ---- - 1 +DROP TABLE temptest; +SELECT * FROM temptest; + col +----- + 1 (1 row) -QUERY: DROP TABLE temptest; -QUERY: CREATE TEMP TABLE temptest(col int); -QUERY: SELECT * FROM temptest; +DROP TABLE temptest; +CREATE TEMP TABLE temptest(col int); +-- test temp table deletion +\c regression +SELECT * FROM temptest; ERROR: Relation 'temptest' does not exist diff --git a/src/test/regress/expected/transactions.out b/src/test/regress/expected/transactions.out index 1aa5a67c88..46afaa3aad 100644 --- a/src/test/regress/expected/transactions.out +++ b/src/test/regress/expected/transactions.out @@ -1,35 +1,42 @@ -QUERY: BEGIN; -QUERY: SELECT * +-- +-- TRANSACTIONS +-- +BEGIN; +SELECT * INTO TABLE xacttest FROM aggtest; -QUERY: INSERT INTO xacttest (a, b) VALUES (777, 777.777); -QUERY: END; -QUERY: SELECT a FROM xacttest WHERE a > 100; - a ---- -777 +INSERT INTO xacttest (a, b) VALUES (777, 777.777); +END; +-- should retrieve one value-- +SELECT a FROM xacttest WHERE a > 100; + a +----- + 777 (1 row) -QUERY: BEGIN; -QUERY: CREATE TABLE disappear (a int4); -QUERY: DELETE FROM aggtest; -QUERY: SELECT * FROM aggtest; -a|b --+- +BEGIN; +CREATE TABLE disappear (a int4); +DELETE FROM aggtest; +-- should be empty +SELECT * FROM aggtest; + a | b +---+--- (0 rows) -QUERY: ABORT; -QUERY: SELECT oid FROM pg_class WHERE relname = 'disappear'; -oid ---- +ABORT; +-- should not exist +SELECT oid FROM pg_class WHERE relname = 'disappear'; + oid +----- (0 rows) -QUERY: SELECT * FROM aggtest; - a| b ----+------- - 56| 7.8 -100| 99.097 - 0|0.09561 - 42| 324.78 +-- should have members again +SELECT * FROM aggtest; + a | b +-----+--------- + 56 | 7.8 + 100 | 99.097 + 0 | 0.09561 + 42 | 324.78 (4 rows)