Commit 9c1b2981 authored by Thomas G. Lockhart's avatar Thomas G. Lockhart

Update output to new psql conventions.

parent 6033cfd4
QUERY: CREATE AGGREGATE newavg (
sfunc1 = int4pl, basetype = int4, stype1 = int4,
--
-- CREATE_AGGREGATE
--
-- all functions CREATEd
CREATE AGGREGATE newavg (
sfunc1 = int4pl, basetype = int4, stype1 = int4,
sfunc2 = int4inc, stype2 = int4,
finalfunc = int4div,
initcond1 = '0', initcond2 = '0'
);
QUERY: CREATE AGGREGATE newsum (
sfunc1 = int4pl, basetype = int4, stype1 = int4,
-- sfunc1 (value-dependent) only
CREATE AGGREGATE newsum (
sfunc1 = int4pl, basetype = int4, stype1 = int4,
initcond1 = '0'
);
QUERY: CREATE AGGREGATE newcnt (
sfunc2 = int4inc, basetype = int4, stype2 = int4,
-- sfunc2 (value-independent) only
CREATE AGGREGATE newcnt (
sfunc2 = int4inc, basetype = int4, stype2 = int4,
initcond2 = '0'
);
QUERY: CREATE INDEX onek_unique1 ON onek USING btree(unique1 int4_ops);
QUERY: CREATE INDEX onek_unique2 ON onek USING btree(unique2 int4_ops);
QUERY: CREATE INDEX onek_hundred ON onek USING btree(hundred int4_ops);
QUERY: CREATE INDEX onek_stringu1 ON onek USING btree(stringu1 name_ops);
QUERY: CREATE INDEX tenk1_unique1 ON tenk1 USING btree(unique1 int4_ops);
QUERY: CREATE INDEX tenk1_unique2 ON tenk1 USING btree(unique2 int4_ops);
QUERY: CREATE INDEX tenk1_hundred ON tenk1 USING btree(hundred int4_ops);
QUERY: CREATE INDEX tenk2_unique1 ON tenk2 USING btree(unique1 int4_ops);
QUERY: CREATE INDEX tenk2_unique2 ON tenk2 USING btree(unique2 int4_ops);
QUERY: CREATE INDEX tenk2_hundred ON tenk2 USING btree(hundred int4_ops);
QUERY: CREATE INDEX rix ON road USING btree (name text_ops);
QUERY: CREATE INDEX iix ON ihighway USING btree (name text_ops);
QUERY: CREATE INDEX six ON shighway USING btree (name text_ops);
QUERY: CREATE INDEX bt_i4_index ON bt_i4_heap USING btree (seqno int4_ops);
QUERY: CREATE INDEX bt_name_index ON bt_name_heap USING btree (seqno name_ops);
QUERY: CREATE INDEX bt_txt_index ON bt_txt_heap USING btree (seqno text_ops);
QUERY: CREATE INDEX bt_f8_index ON bt_f8_heap USING btree (seqno float8_ops);
QUERY: CREATE INDEX rect2ind ON fast_emp4000 USING rtree (home_base bigbox_ops);
QUERY: CREATE INDEX hash_i4_index ON hash_i4_heap USING hash (random int4_ops);
QUERY: CREATE INDEX hash_name_index ON hash_name_heap USING hash (random name_ops);
QUERY: CREATE INDEX hash_txt_index ON hash_txt_heap USING hash (random text_ops);
QUERY: CREATE INDEX hash_f8_index ON hash_f8_heap USING hash (random float8_ops);
--
-- CREATE_INDEX
-- Create ancillary data structures (i.e. indices)
--
--
-- BTREE
--
CREATE INDEX onek_unique1 ON onek USING btree(unique1 int4_ops);
CREATE INDEX onek_unique2 ON onek USING btree(unique2 int4_ops);
CREATE INDEX onek_hundred ON onek USING btree(hundred int4_ops);
CREATE INDEX onek_stringu1 ON onek USING btree(stringu1 name_ops);
CREATE INDEX tenk1_unique1 ON tenk1 USING btree(unique1 int4_ops);
CREATE INDEX tenk1_unique2 ON tenk1 USING btree(unique2 int4_ops);
CREATE INDEX tenk1_hundred ON tenk1 USING btree(hundred int4_ops);
CREATE INDEX tenk2_unique1 ON tenk2 USING btree(unique1 int4_ops);
CREATE INDEX tenk2_unique2 ON tenk2 USING btree(unique2 int4_ops);
CREATE INDEX tenk2_hundred ON tenk2 USING btree(hundred int4_ops);
CREATE INDEX rix ON road USING btree (name text_ops);
CREATE INDEX iix ON ihighway USING btree (name text_ops);
CREATE INDEX six ON shighway USING btree (name text_ops);
--
-- BTREE ascending/descending cases
--
-- we load int4/text from pure descending data (each key is a new
-- low key) and name/f8 from pure ascending data (each key is a new
-- high key). we had a bug where new low keys would sometimes be
-- "lost".
--
CREATE INDEX bt_i4_index ON bt_i4_heap USING btree (seqno int4_ops);
CREATE INDEX bt_name_index ON bt_name_heap USING btree (seqno name_ops);
CREATE INDEX bt_txt_index ON bt_txt_heap USING btree (seqno text_ops);
CREATE INDEX bt_f8_index ON bt_f8_heap USING btree (seqno float8_ops);
--
-- BTREE partial indices
-- partial indices are not supported in PostgreSQL
--
--CREATE INDEX onek2_u1_prtl ON onek2 USING btree(unique1 int4_ops)
-- where onek2.unique1 < 20 or onek2.unique1 > 980;
--CREATE INDEX onek2_u2_prtl ON onek2 USING btree(unique2 int4_ops)
-- where onek2.stringu1 < 'B';
-- EXTEND INDEX onek2_u2_prtl where onek2.stringu1 < 'C';
-- EXTEND INDEX onek2_u2_prtl;
-- CREATE INDEX onek2_stu1_prtl ON onek2 USING btree(stringu1 name_ops)
-- where onek2.stringu1 >= 'J' and onek2.stringu1 < 'K';
--
-- RTREE
--
-- rtrees use a quadratic page-splitting algorithm that takes a
-- really, really long time. we don't test all rtree opclasses
-- in the regression test (we check them USING the sequoia 2000
-- benchmark).
--
CREATE INDEX rect2ind ON fast_emp4000 USING rtree (home_base bigbox_ops);
--
-- HASH
--
CREATE INDEX hash_i4_index ON hash_i4_heap USING hash (random int4_ops);
CREATE INDEX hash_name_index ON hash_name_heap USING hash (random name_ops);
CREATE INDEX hash_txt_index ON hash_txt_heap USING hash (random text_ops);
CREATE INDEX hash_f8_index ON hash_f8_heap USING hash (random float8_ops);
-- CREATE INDEX hash_ovfl_index ON hash_ovfl_heap USING hash (x int4_ops);
QUERY: INSERT INTO tenk2 VALUES (tenk1.*);
QUERY: SELECT * INTO TABLE onek2 FROM onek;
QUERY: INSERT INTO fast_emp4000 VALUES (slow_emp4000.*);
QUERY: SELECT *
--
-- CREATE_MISC
--
-- CLASS POPULATION
-- (any resemblance to real life is purely coincidental)
--
INSERT INTO tenk2 VALUES (tenk1.*);
SELECT * INTO TABLE onek2 FROM onek;
INSERT INTO fast_emp4000 VALUES (slow_emp4000.*);
SELECT *
INTO TABLE Bprime
FROM tenk1
WHERE unique2 < 1000;
QUERY: INSERT INTO hobbies_r (name, person)
INSERT INTO hobbies_r (name, person)
SELECT 'posthacking', p.name
FROM person* p
WHERE p.name = 'mike' or p.name = 'jeff';
QUERY: INSERT INTO hobbies_r (name, person)
INSERT INTO hobbies_r (name, person)
SELECT 'basketball', p.name
FROM person p
WHERE p.name = 'joe' or p.name = 'sally';
QUERY: INSERT INTO hobbies_r (name) VALUES ('skywalking');
QUERY: INSERT INTO equipment_r (name, hobby) VALUES ('advil', 'posthacking');
QUERY: INSERT INTO equipment_r (name, hobby) VALUES ('peet''s coffee', 'posthacking');
QUERY: INSERT INTO equipment_r (name, hobby) VALUES ('hightops', 'basketball');
QUERY: INSERT INTO equipment_r (name, hobby) VALUES ('guts', 'skywalking');
QUERY: SELECT *
INSERT INTO hobbies_r (name) VALUES ('skywalking');
INSERT INTO equipment_r (name, hobby) VALUES ('advil', 'posthacking');
INSERT INTO equipment_r (name, hobby) VALUES ('peet''s coffee', 'posthacking');
INSERT INTO equipment_r (name, hobby) VALUES ('hightops', 'basketball');
INSERT INTO equipment_r (name, hobby) VALUES ('guts', 'skywalking');
SELECT *
INTO TABLE ramp
FROM road
WHERE name ~ '.*Ramp';
QUERY: INSERT INTO ihighway
SELECT *
FROM road
INSERT INTO ihighway
SELECT *
FROM road
WHERE name ~ 'I- .*';
QUERY: INSERT INTO shighway
SELECT *
FROM road
INSERT INTO shighway
SELECT *
FROM road
WHERE name ~ 'State Hwy.*';
QUERY: UPDATE shighway
UPDATE shighway
SET surface = 'asphalt';
QUERY: INSERT INTO a_star (class, a) VALUES ('a', 1);
QUERY: INSERT INTO a_star (class, a) VALUES ('a', 2);
QUERY: INSERT INTO a_star (class) VALUES ('a');
QUERY: INSERT INTO b_star (class, a, b) VALUES ('b', 3, 'mumble'::text);
QUERY: INSERT INTO b_star (class, a) VALUES ('b', 4);
QUERY: INSERT INTO b_star (class, b) VALUES ('b', 'bumble'::text);
QUERY: INSERT INTO b_star (class) VALUES ('b');
QUERY: INSERT INTO c_star (class, a, c) VALUES ('c', 5, 'hi mom'::name);
QUERY: INSERT INTO c_star (class, a) VALUES ('c', 6);
QUERY: INSERT INTO c_star (class, c) VALUES ('c', 'hi paul'::name);
QUERY: INSERT INTO c_star (class) VALUES ('c');
QUERY: INSERT INTO d_star (class, a, b, c, d)
INSERT INTO a_star (class, a) VALUES ('a', 1);
INSERT INTO a_star (class, a) VALUES ('a', 2);
INSERT INTO a_star (class) VALUES ('a');
INSERT INTO b_star (class, a, b) VALUES ('b', 3, 'mumble'::text);
INSERT INTO b_star (class, a) VALUES ('b', 4);
INSERT INTO b_star (class, b) VALUES ('b', 'bumble'::text);
INSERT INTO b_star (class) VALUES ('b');
INSERT INTO c_star (class, a, c) VALUES ('c', 5, 'hi mom'::name);
INSERT INTO c_star (class, a) VALUES ('c', 6);
INSERT INTO c_star (class, c) VALUES ('c', 'hi paul'::name);
INSERT INTO c_star (class) VALUES ('c');
INSERT INTO d_star (class, a, b, c, d)
VALUES ('d', 7, 'grumble'::text, 'hi sunita'::name, '0.0'::float8);
QUERY: INSERT INTO d_star (class, a, b, c)
INSERT INTO d_star (class, a, b, c)
VALUES ('d', 8, 'stumble'::text, 'hi koko'::name);
QUERY: INSERT INTO d_star (class, a, b, d)
INSERT INTO d_star (class, a, b, d)
VALUES ('d', 9, 'rumble'::text, '1.1'::float8);
QUERY: INSERT INTO d_star (class, a, c, d)
INSERT INTO d_star (class, a, c, d)
VALUES ('d', 10, 'hi kristin'::name, '10.01'::float8);
QUERY: INSERT INTO d_star (class, b, c, d)
INSERT INTO d_star (class, b, c, d)
VALUES ('d', 'crumble'::text, 'hi boris'::name, '100.001'::float8);
QUERY: INSERT INTO d_star (class, a, b)
INSERT INTO d_star (class, a, b)
VALUES ('d', 11, 'fumble'::text);
QUERY: INSERT INTO d_star (class, a, c)
INSERT INTO d_star (class, a, c)
VALUES ('d', 12, 'hi avi'::name);
QUERY: INSERT INTO d_star (class, a, d)
INSERT INTO d_star (class, a, d)
VALUES ('d', 13, '1000.0001'::float8);
QUERY: INSERT INTO d_star (class, b, c)
INSERT INTO d_star (class, b, c)
VALUES ('d', 'tumble'::text, 'hi andrew'::name);
QUERY: INSERT INTO d_star (class, b, d)
INSERT INTO d_star (class, b, d)
VALUES ('d', 'humble'::text, '10000.00001'::float8);
QUERY: INSERT INTO d_star (class, c, d)
INSERT INTO d_star (class, c, d)
VALUES ('d', 'hi ginger'::name, '100000.000001'::float8);
QUERY: INSERT INTO d_star (class, a) VALUES ('d', 14);
QUERY: INSERT INTO d_star (class, b) VALUES ('d', 'jumble'::text);
QUERY: INSERT INTO d_star (class, c) VALUES ('d', 'hi jolly'::name);
QUERY: INSERT INTO d_star (class, d) VALUES ('d', '1000000.0000001'::float8);
QUERY: INSERT INTO d_star (class) VALUES ('d');
QUERY: INSERT INTO e_star (class, a, c, e)
INSERT INTO d_star (class, a) VALUES ('d', 14);
INSERT INTO d_star (class, b) VALUES ('d', 'jumble'::text);
INSERT INTO d_star (class, c) VALUES ('d', 'hi jolly'::name);
INSERT INTO d_star (class, d) VALUES ('d', '1000000.0000001'::float8);
INSERT INTO d_star (class) VALUES ('d');
INSERT INTO e_star (class, a, c, e)
VALUES ('e', 15, 'hi carol'::name, '-1'::int2);
QUERY: INSERT INTO e_star (class, a, c)
INSERT INTO e_star (class, a, c)
VALUES ('e', 16, 'hi bob'::name);
QUERY: INSERT INTO e_star (class, a, e)
INSERT INTO e_star (class, a, e)
VALUES ('e', 17, '-2'::int2);
QUERY: INSERT INTO e_star (class, c, e)
INSERT INTO e_star (class, c, e)
VALUES ('e', 'hi michelle'::name, '-3'::int2);
QUERY: INSERT INTO e_star (class, a)
INSERT INTO e_star (class, a)
VALUES ('e', 18);
QUERY: INSERT INTO e_star (class, c)
INSERT INTO e_star (class, c)
VALUES ('e', 'hi elisa'::name);
QUERY: INSERT INTO e_star (class, e)
INSERT INTO e_star (class, e)
VALUES ('e', '-4'::int2);
QUERY: INSERT INTO f_star (class, a, c, e, f)
INSERT INTO f_star (class, a, c, e, f)
VALUES ('f', 19, 'hi claire'::name, '-5'::int2, '(1,3),(2,4)'::polygon);
QUERY: INSERT INTO f_star (class, a, c, e)
INSERT INTO f_star (class, a, c, e)
VALUES ('f', 20, 'hi mike'::name, '-6'::int2);
QUERY: INSERT INTO f_star (class, a, c, f)
INSERT INTO f_star (class, a, c, f)
VALUES ('f', 21, 'hi marcel'::name, '(11,44),(22,55),(33,66)'::polygon);
QUERY: INSERT INTO f_star (class, a, e, f)
INSERT INTO f_star (class, a, e, f)
VALUES ('f', 22, '-7'::int2, '(111,555),(222,666),(333,777),(444,888)'::polygon);
QUERY: INSERT INTO f_star (class, c, e, f)
VALUES ('f', 'hi keith'::name, '-8'::int2,
INSERT INTO f_star (class, c, e, f)
VALUES ('f', 'hi keith'::name, '-8'::int2,
'(1111,3333),(2222,4444)'::polygon);
QUERY: INSERT INTO f_star (class, a, c)
INSERT INTO f_star (class, a, c)
VALUES ('f', 24, 'hi marc'::name);
QUERY: INSERT INTO f_star (class, a, e)
INSERT INTO f_star (class, a, e)
VALUES ('f', 25, '-9'::int2);
QUERY: INSERT INTO f_star (class, a, f)
VALUES ('f', 26, '(11111,33333),(22222,44444)'::polygon);
QUERY: INSERT INTO f_star (class, c, e)
INSERT INTO f_star (class, a, f)
VALUES ('f', 26, '(11111,33333),(22222,44444)'::polygon);
INSERT INTO f_star (class, c, e)
VALUES ('f', 'hi allison'::name, '-10'::int2);
QUERY: INSERT INTO f_star (class, c, f)
INSERT INTO f_star (class, c, f)
VALUES ('f', 'hi jeff'::name,
'(111111,333333),(222222,444444)'::polygon);
QUERY: INSERT INTO f_star (class, e, f)
INSERT INTO f_star (class, e, f)
VALUES ('f', '-11'::int2, '(1111111,3333333),(2222222,4444444)'::polygon);
QUERY: INSERT INTO f_star (class, a) VALUES ('f', 27);
QUERY: INSERT INTO f_star (class, c) VALUES ('f', 'hi carl'::name);
QUERY: INSERT INTO f_star (class, e) VALUES ('f', '-12'::int2);
QUERY: INSERT INTO f_star (class, f)
INSERT INTO f_star (class, a) VALUES ('f', 27);
INSERT INTO f_star (class, c) VALUES ('f', 'hi carl'::name);
INSERT INTO f_star (class, e) VALUES ('f', '-12'::int2);
INSERT INTO f_star (class, f)
VALUES ('f', '(11111111,33333333),(22222222,44444444)'::polygon);
QUERY: INSERT INTO f_star (class) VALUES ('f');
QUERY: INSERT INTO arrtest (a[5], b[2][1][2], c, d, f, g)
INSERT INTO f_star (class) VALUES ('f');
--
-- ARRAYS
--
--
-- only this array as a 0-based 'e', the others are 1-based.
-- 'e' is also a large object.
--
INSERT INTO arrtest (a[5], b[2][1][2], c, d, f, g)
VALUES ('{1,2,3,4,5}', '{{{},{1,2}}}', '{}', '{}', '{}', '{}');
QUERY: UPDATE arrtest SET e[0] = '1.1';
QUERY: UPDATE arrtest SET e[1] = '2.2';
QUERY: INSERT INTO arrtest (a, b[2][2][1], c, d, e, f, g)
VALUES ('{11,12,23}', '{{3,4},{4,5}}', '{"foobar"}',
UPDATE arrtest SET e[0] = '1.1';
UPDATE arrtest SET e[1] = '2.2';
INSERT INTO arrtest (a, b[2][2][1], c, d, e, f, g)
VALUES ('{11,12,23}', '{{3,4},{4,5}}', '{"foobar"}',
'{{"elt1", "elt2"}}', '{"3.4", "6.7"}',
'{"abc","abcdefgh"}', '{"abc","abcdefgh"}');
QUERY: INSERT INTO arrtest (a, b[1][2][2], c, d[2][1])
INSERT INTO arrtest (a, b[1][2][2], c, d[2][1])
VALUES ('{}', '{3,4}', '{foo,bar}', '{bar,foo}');
QUERY: CREATE TABLE iportaltest (
i int4,
d float4,
--
-- for internal portal (cursor) tests
--
CREATE TABLE iportaltest (
i int4,
d float4,
p polygon
);
QUERY: INSERT INTO iportaltest (i, d, p)
INSERT INTO iportaltest (i, d, p)
VALUES (1, 3.567, '(3.0,1.0),(4.0,2.0)'::polygon);
QUERY: INSERT INTO iportaltest (i, d, p)
INSERT INTO iportaltest (i, d, p)
VALUES (2, 89.05, '(4.0,2.0),(3.0,1.0)'::polygon);
QUERY: CREATE OPERATOR ## (
--
-- CREATE_OPERATOR
--
CREATE OPERATOR ## (
leftarg = path,
rightarg = path,
procedure = path_inter,
commutator = ##
commutator = ##
);
QUERY: CREATE OPERATOR <% (
CREATE OPERATOR <% (
leftarg = point,
rightarg = widget,
procedure = pt_in_widget,
commutator = >% ,
negator = >=%
negator = >=%
);
QUERY: CREATE OPERATOR @#@ (
rightarg = int4,
procedure = int4fac
CREATE OPERATOR @#@ (
rightarg = int4, -- left unary
procedure = int4fac
);
QUERY: CREATE OPERATOR #@# (
leftarg = int4,
procedure = int4fac
CREATE OPERATOR #@# (
leftarg = int4, -- right unary
procedure = int4fac
);
QUERY: CREATE OPERATOR #%# (
leftarg = int4,
procedure = int4fac
CREATE OPERATOR #%# (
leftarg = int4, -- right unary
procedure = int4fac
);
QUERY: CREATE TABLE hobbies_r (
name text,
--
-- CREATE_TABLE
--
--
-- CLASS DEFINITIONS
--
CREATE TABLE hobbies_r (
name text,
person text
);
QUERY: CREATE TABLE equipment_r (
CREATE TABLE equipment_r (
name text,
hobby text
);
QUERY: CREATE TABLE onek (
CREATE TABLE onek (
unique1 int4,
unique2 int4,
two int4,
two int4,
four int4,
ten int4,
ten int4,
twenty int4,
hundred int4,
thousand int4,
twothousand int4,
fivethous int4,
tenthous int4,
odd int4,
odd int4,
even int4,
stringu1 name,
stringu2 name,
string4 name
);
QUERY: CREATE TABLE tenk1 (
CREATE TABLE tenk1 (
unique1 int4,
unique2 int4,
two int4,
two int4,
four int4,
ten int4,
ten int4,
twenty int4,
hundred int4,
thousand int4,
twothousand int4,
fivethous int4,
tenthous int4,
odd int4,
odd int4,
even int4,
stringu1 name,
stringu2 name,
string4 name
);
QUERY: CREATE TABLE tenk2 (
CREATE TABLE tenk2 (
unique1 int4,
unique2 int4,
two int4,
four int4,
ten int4,
ten int4,
twenty int4,
hundred int4,
thousand int4,
twothousand int4,
twothousand int4,
fivethous int4,
tenthous int4,
odd int4,
odd int4,
even int4,
stringu1 name,
stringu2 name,
string4 name
);
QUERY: CREATE TABLE person (
CREATE TABLE person (
name text,
age int4,
age int4,
location point
);
QUERY: CREATE TABLE emp (
CREATE TABLE emp (
salary int4,
manager name
) INHERITS (person);
QUERY: CREATE TABLE student (
CREATE TABLE student (
gpa float8
) INHERITS (person);
QUERY: CREATE TABLE stud_emp (
CREATE TABLE stud_emp (
percent int4
) INHERITS (emp, student);
QUERY: CREATE TABLE city (
CREATE TABLE city (
name name,
location box,
budget city_budget
);
QUERY: CREATE TABLE dept (
CREATE TABLE dept (
dname name,
mgrname text
);
QUERY: CREATE TABLE slow_emp4000 (
CREATE TABLE slow_emp4000 (
home_base box
);
QUERY: CREATE TABLE fast_emp4000 (
CREATE TABLE fast_emp4000 (
home_base box
);
QUERY: CREATE TABLE road (
CREATE TABLE road (
name text,
thepath path
);
QUERY: CREATE TABLE ihighway () INHERITS (road);
QUERY: CREATE TABLE shighway (
CREATE TABLE ihighway () INHERITS (road);
CREATE TABLE shighway (
surface text
) INHERITS (road);
QUERY: CREATE TABLE real_city (
pop int4,
CREATE TABLE real_city (
pop int4,
cname text,
outline path
);
QUERY: CREATE TABLE a_star (
class char,
a int4
);
QUERY: CREATE TABLE b_star (
b text
--
-- test the "star" operators a bit more thoroughly -- this time,
-- throw in lots of NULL fields...
--
-- a is the type root
-- b and c inherit from a (one-level single inheritance)
-- d inherits from b and c (two-level multiple inheritance)
-- e inherits from c (two-level single inheritance)
-- f inherits from e (three-level single inheritance)
--
CREATE TABLE a_star (
class char,
a int4
);
CREATE TABLE b_star (
b text
) INHERITS (a_star);
QUERY: CREATE TABLE c_star (
c name
CREATE TABLE c_star (
c name
) INHERITS (a_star);
QUERY: CREATE TABLE d_star (
d float8
CREATE TABLE d_star (
d float8
) INHERITS (b_star, c_star);
QUERY: CREATE TABLE e_star (
e int2
CREATE TABLE e_star (
e int2
) INHERITS (c_star);
QUERY: CREATE TABLE f_star (
f polygon
CREATE TABLE f_star (
f polygon
) INHERITS (e_star);
QUERY: CREATE TABLE aggtest (
a int2,
b float4
);
QUERY: CREATE TABLE arrtest (
a int2[],
b int4[][][],
c name[],
d text[][],
e float8[],
f char(5)[],
g varchar(5)[]
);
QUERY: CREATE TABLE hash_i4_heap (
CREATE TABLE aggtest (
a int2,
b float4
);
CREATE TABLE arrtest (
a int2[],
b int4[][][],
c name[],
d text[][],
e float8[],
f char(5)[],
g varchar(5)[]
);
CREATE TABLE hash_i4_heap (
seqno int4,
random int4
);
QUERY: CREATE TABLE hash_name_heap (
CREATE TABLE hash_name_heap (
seqno int4,
random name
);
QUERY: CREATE TABLE hash_txt_heap (
CREATE TABLE hash_txt_heap (
seqno int4,
random text
);
QUERY: CREATE TABLE hash_f8_heap (
CREATE TABLE hash_f8_heap (
seqno int4,
random float8
);
QUERY: CREATE TABLE bt_i4_heap (
-- don't include the hash_ovfl_heap stuff in the distribution
-- the data set is too large for what it's worth
--
-- CREATE TABLE hash_ovfl_heap (
-- x int4,
-- y int4
-- );
CREATE TABLE bt_i4_heap (
seqno int4,
random int4
);
QUERY: CREATE TABLE bt_name_heap (
CREATE TABLE bt_name_heap (
seqno name,
random int4
);
QUERY: CREATE TABLE bt_txt_heap (
CREATE TABLE bt_txt_heap (
seqno text,
random int4
);
QUERY: CREATE TABLE bt_f8_heap (
seqno float8,
CREATE TABLE bt_f8_heap (
seqno float8,
random int4
);
QUERY: CREATE TYPE widget (
internallength = 24,
--
-- CREATE_TYPE
--
CREATE TYPE widget (
internallength = 24,
input = widget_in,
output = widget_out,
alignment = double
);
QUERY: CREATE TYPE city_budget (
internallength = 16,
input = int44in,
output = int44out,
CREATE TYPE city_budget (
internallength = 16,
input = int44in,
output = int44out,
element = int4
);
QUERY: CREATE VIEW street AS
SELECT r.name, r.thepath, c.cname AS cname
--
-- CREATE_VIEW
-- Virtual class definitions
-- (this also tests the query rewrite system)
--
CREATE VIEW street AS
SELECT r.name, r.thepath, c.cname AS cname
FROM road r, real_city c
WHERE c.outline ## r.thepath;
QUERY: CREATE VIEW iexit AS
SELECT ih.name, ih.thepath,
CREATE VIEW iexit AS
SELECT ih.name, ih.thepath,
interpt_pp(ih.thepath, r.thepath) AS exit
FROM ihighway ih, ramp r
WHERE ih.thepath ## r.thepath;
QUERY: CREATE VIEW toyemp AS
CREATE VIEW toyemp AS
SELECT name, age, location, 12*salary AS annualsal
FROM emp;
This diff is collapsed.
QUERY: VACUUM;
QUERY: SELECT relname, relhasindex
VACUUM;
--
-- sanity check, if we don't have indices the test will take years to
-- complete.
--
SELECT relname, relhasindex
FROM pg_class
WHERE relhasindex
ORDER BY relname;
relname |relhasindex
--------------+-----------
bt_f8_heap |t
bt_i4_heap |t
bt_name_heap |t
bt_txt_heap |t
fast_emp4000 |t
hash_f8_heap |t
hash_i4_heap |t
hash_name_heap|t
hash_txt_heap |t
ihighway |t
onek |t
pg_aggregate |t
pg_am |t
pg_amop |t
pg_attrdef |t
pg_attribute |t
pg_class |t
pg_description|t
pg_group |t
pg_index |t
pg_inherits |t
pg_language |t
pg_listener |t
pg_opclass |t
pg_operator |t
pg_proc |t
pg_relcheck |t
pg_rewrite |t
pg_statistic |t
pg_trigger |t
pg_type |t
road |t
shighway |t
tenk1 |t
tenk2 |t
(35 rows)
relname | relhasindex
---------------------+-------------
bt_f8_heap | t
bt_i4_heap | t
bt_name_heap | t
bt_txt_heap | t
fast_emp4000 | t
hash_f8_heap | t
hash_i4_heap | t
hash_name_heap | t
hash_txt_heap | t
ihighway | t
num_exp_add | t
num_exp_div | t
num_exp_ln | t
num_exp_log10 | t
num_exp_mul | t
num_exp_power_10_ln | t
num_exp_sqrt | t
num_exp_sub | t
onek | t
pg_aggregate | t
pg_am | t
pg_amop | t
pg_attrdef | t
pg_attribute | t
pg_class | t
pg_description | t
pg_group | t
pg_index | t
pg_inherits | t
pg_language | t
pg_listener | t
pg_opclass | t
pg_operator | t
pg_proc | t
pg_relcheck | t
pg_rewrite | t
pg_statistic | t
pg_trigger | t
pg_type | t
road | t
shighway | t
tenk1 | t
tenk2 | t
(43 rows)
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment