OSDN Git Service

No.A-6の試験のPG9.1用予測結果を更新した。
[pghintplan/pg_hint_plan.git] / expected / init-9.1.out
1 SET search_path TO public;
2 CREATE EXTENSION pg_hint_plan;
3 CREATE SCHEMA s0;
4 CREATE TABLE t1 (id int PRIMARY KEY, val int);
5 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "t1_pkey" for table "t1"
6 CREATE TABLE t2 (id int PRIMARY KEY, val int);
7 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "t2_pkey" for table "t2"
8 CREATE TABLE t3 (id int PRIMARY KEY, val int);
9 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "t3_pkey" for table "t3"
10 CREATE TABLE t4 (id int PRIMARY KEY, val int);
11 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "t4_pkey" for table "t4"
12 CREATE TABLE t5 (id int PRIMARY KEY, val int);
13 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "t5_pkey" for table "t5"
14 CREATE TABLE p1 (id int PRIMARY KEY, val int);
15 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p1_pkey" for table "p1"
16 CREATE TABLE p1_c1 (LIKE p1 INCLUDING ALL, CHECK (id <= 100)) INHERITS(p1);
17 NOTICE:  merging column "id" with inherited definition
18 NOTICE:  merging column "val" with inherited definition
19 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p1_c1_pkey" for table "p1_c1"
20 CREATE TABLE p1_c2 (LIKE p1 INCLUDING ALL, CHECK (id > 100 AND id <= 200)) INHERITS(p1);
21 NOTICE:  merging column "id" with inherited definition
22 NOTICE:  merging column "val" with inherited definition
23 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p1_c2_pkey" for table "p1_c2"
24 CREATE TABLE p1_c3 (LIKE p1 INCLUDING ALL, CHECK (id > 200 AND id <= 300)) INHERITS(p1);
25 NOTICE:  merging column "id" with inherited definition
26 NOTICE:  merging column "val" with inherited definition
27 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p1_c3_pkey" for table "p1_c3"
28 CREATE TABLE p1_c4 (LIKE p1 INCLUDING ALL, CHECK (id > 300)) INHERITS(p1);
29 NOTICE:  merging column "id" with inherited definition
30 NOTICE:  merging column "val" with inherited definition
31 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p1_c4_pkey" for table "p1_c4"
32 CREATE TABLE p1_c1_c1 (LIKE p1 INCLUDING ALL, CHECK (id <= 50)) INHERITS(p1_c1);
33 NOTICE:  merging column "id" with inherited definition
34 NOTICE:  merging column "val" with inherited definition
35 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p1_c1_c1_pkey" for table "p1_c1_c1"
36 CREATE TABLE p1_c1_c2 (LIKE p1 INCLUDING ALL, CHECK (id > 50 AND id <= 100)) INHERITS(p1_c1);
37 NOTICE:  merging column "id" with inherited definition
38 NOTICE:  merging column "val" with inherited definition
39 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p1_c1_c2_pkey" for table "p1_c1_c2"
40 CREATE TABLE p1_c3_c1 (LIKE p1 INCLUDING ALL, CHECK (id > 200 AND id <= 250)) INHERITS(p1_c3);
41 NOTICE:  merging column "id" with inherited definition
42 NOTICE:  merging column "val" with inherited definition
43 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p1_c3_c1_pkey" for table "p1_c3_c1"
44 CREATE TABLE p1_c3_c2 (LIKE p1 INCLUDING ALL, CHECK (id > 250 AND id <= 300)) INHERITS(p1_c3);
45 NOTICE:  merging column "id" with inherited definition
46 NOTICE:  merging column "val" with inherited definition
47 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p1_c3_c2_pkey" for table "p1_c3_c2"
48 CREATE TABLE p2 (id int PRIMARY KEY, val text);
49 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p2_pkey" for table "p2"
50 CREATE INDEX p2_id_val_idx ON p2 (id, val);
51 CREATE UNIQUE INDEX p2_val_idx ON p2 (val);
52 CREATE INDEX p2_ununi_id_val_idx ON p2 (val);
53 CREATE INDEX p2_val_idx_1 ON p2 USING hash (val);
54 CREATE INDEX p2_val_id_idx ON p2 (val, id);
55 CREATE INDEX p2_val_idx2 ON p2 (val COLLATE "ja_JP");
56 CREATE INDEX p2_val_idx3 ON p2 (val varchar_ops);
57 CREATE INDEX p2_val_idx4 ON p2 (val DESC NULLS LAST);
58 CREATE INDEX p2_val_idx5 ON p2 (val NULLS FIRST);
59 CREATE INDEX p2_expr ON p2 ((val < '120'));
60 CREATE INDEX p2_expr2 ON p2 ((id * 2 < 120));
61 CREATE INDEX p2_val_idx6 ON p2 (val) WHERE val >= '50' AND val < '51';
62 CREATE INDEX p2_val_idx7 ON p2 (val) WHERE id < 120;
63 CREATE TABLE p2_c1 (LIKE p2 INCLUDING ALL, CHECK (id <= 100)) INHERITS(p2);
64 NOTICE:  merging column "id" with inherited definition
65 NOTICE:  merging column "val" with inherited definition
66 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p2_c1_pkey" for table "p2_c1"
67 CREATE TABLE p2_c2 (LIKE p2 INCLUDING ALL, CHECK (id > 100 AND id <= 200)) INHERITS(p2);
68 NOTICE:  merging column "id" with inherited definition
69 NOTICE:  merging column "val" with inherited definition
70 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p2_c2_pkey" for table "p2_c2"
71 CREATE TABLE p2_c3 (LIKE p2 INCLUDING ALL, CHECK (id > 200 AND id <= 300)) INHERITS(p2);
72 NOTICE:  merging column "id" with inherited definition
73 NOTICE:  merging column "val" with inherited definition
74 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p2_c3_pkey" for table "p2_c3"
75 CREATE TABLE p2_c4 (LIKE p2 INCLUDING ALL, CHECK (id > 300)) INHERITS(p2);
76 NOTICE:  merging column "id" with inherited definition
77 NOTICE:  merging column "val" with inherited definition
78 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p2_c4_pkey" for table "p2_c4"
79 CREATE TABLE p2_c1_c1 (LIKE p2 INCLUDING ALL, CHECK (id <= 50)) INHERITS(p2_c1);
80 NOTICE:  merging column "id" with inherited definition
81 NOTICE:  merging column "val" with inherited definition
82 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p2_c1_c1_pkey" for table "p2_c1_c1"
83 CREATE TABLE p2_c1_c2 (LIKE p2 INCLUDING ALL, CHECK (id > 50 AND id <= 100)) INHERITS(p2_c1);
84 NOTICE:  merging column "id" with inherited definition
85 NOTICE:  merging column "val" with inherited definition
86 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p2_c1_c2_pkey" for table "p2_c1_c2"
87 CREATE TABLE p2_c3_c1 (LIKE p2 INCLUDING ALL, CHECK (id > 200 AND id <= 250)) INHERITS(p2_c3);
88 NOTICE:  merging column "id" with inherited definition
89 NOTICE:  merging column "val" with inherited definition
90 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p2_c3_c1_pkey" for table "p2_c3_c1"
91 CREATE TABLE p2_c3_c2 (LIKE p2 INCLUDING ALL, CHECK (id > 250 AND id <= 300)) INHERITS(p2_c3);
92 NOTICE:  merging column "id" with inherited definition
93 NOTICE:  merging column "val" with inherited definition
94 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "p2_c3_c2_pkey" for table "p2_c3_c2"
95 CREATE TABLE s0.t1 (id int PRIMARY KEY, val int);
96 NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "t1_pkey" for table "t1"
97 INSERT INTO t1 SELECT i, i % 100 FROM (SELECT generate_series(1, 10000) i) t;
98 INSERT INTO t2 SELECT i, i % 10 FROM (SELECT generate_series(1, 1000) i) t;
99 INSERT INTO t3 SELECT i, i FROM (SELECT generate_series(1, 100) i) t;
100 INSERT INTO t4 SELECT i, i FROM (SELECT generate_series(1, 10) i) t;
101 INSERT INTO t5 SELECT i, i % 100 FROM (SELECT generate_series(1, 10000) i) t;
102 INSERT INTO p1_c1_c1 SELECT i, i % 100 FROM (SELECT generate_series(1, 50) i) t;
103 INSERT INTO p1_c1_c2 SELECT i, i % 100 FROM (SELECT generate_series(51, 100) i) t;
104 INSERT INTO p1_c2 SELECT i, i % 100 FROM (SELECT generate_series(101, 200) i) t;
105 INSERT INTO p1_c3_c1 SELECT i, i % 100 FROM (SELECT generate_series(201, 250) i) t;
106 INSERT INTO p1_c3_c2 SELECT i, i % 100 FROM (SELECT generate_series(251, 300) i) t;
107 INSERT INTO p1_c4 SELECT i, i % 100 FROM (SELECT generate_series(301, 400) i) t;
108 INSERT INTO p2_c1_c1 SELECT i, i % 100 FROM (SELECT generate_series(1, 50) i) t;
109 INSERT INTO p2_c1_c2 SELECT i, i % 100 FROM (SELECT generate_series(51, 100) i) t;
110 INSERT INTO p2_c2 SELECT i, i % 100 FROM (SELECT generate_series(101, 200) i) t;
111 INSERT INTO p2_c3_c1 SELECT i, i % 100 FROM (SELECT generate_series(201, 250) i) t;
112 INSERT INTO p2_c3_c2 SELECT i, i % 100 FROM (SELECT generate_series(251, 300) i) t;
113 INSERT INTO p2_c4 SELECT i, i % 100 FROM (SELECT generate_series(301, 400) i) t;
114 CREATE INDEX t1_val ON t1 (val);
115 CREATE INDEX t2_val ON t2 (val);
116 CREATE INDEX t5_id1 ON t5 (id);
117 CREATE INDEX t5_id2 ON t5 (id);
118 CREATE INDEX t5_id3 ON t5 (id);
119 CREATE INDEX t5_val ON t5 (val);
120 DROP INDEX p2_c4_val_id_idx;
121 CREATE INDEX p2_id2_val ON p2 (id, id, val);
122 CREATE INDEX p2_c1_id2_val ON p2_c1 (id, id, val);
123 CREATE INDEX p2_c2_id2_val ON p2_c2 (id, id, val);
124 CREATE INDEX p2_val2_id ON p2 (val, id, val);
125 CREATE INDEX t5_idaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa ON t5 (id);
126 CREATE INDEX p1_val1 ON p1 (val);
127 CREATE INDEX p1_val2 ON p1 (val);
128 CREATE INDEX p1_val3 ON p1 (val);
129 CREATE INDEX p1_c1_val1 ON p1_c1 (val);
130 CREATE INDEX p1_c1_val2 ON p1_c1 (val);
131 CREATE INDEX p1_c1_val3 ON p1_c1 (val);
132 CREATE INDEX p1_c1_c1_val1 ON p1_c1_c1 (val);
133 CREATE INDEX p1_c1_c1_val2 ON p1_c1_c1 (val);
134 CREATE INDEX p1_c1_c1_val3 ON p1_c1_c1 (val);
135 CREATE INDEX p1_c1_c2_val1 ON p1_c1_c2 (val);
136 CREATE INDEX p1_c1_c2_val2 ON p1_c1_c2 (val);
137 CREATE INDEX p1_c1_c2_val3 ON p1_c1_c2 (val);
138 CREATE INDEX p1_c2_val1 ON p1_c2 (val);
139 CREATE INDEX p1_c2_val2 ON p1_c2 (val);
140 CREATE INDEX p1_c2_val3 ON p1_c2 (val);
141 CREATE INDEX p1_c3_val1 ON p1_c3 (val);
142 CREATE INDEX p1_c3_val2 ON p1_c3 (val);
143 CREATE INDEX p1_c3_val3 ON p1_c3 (val);
144 CREATE INDEX p1_c3_c1_val1 ON p1_c3_c1 (val);
145 CREATE INDEX p1_c3_c1_val2 ON p1_c3_c1 (val);
146 CREATE INDEX p1_c3_c1_val3 ON p1_c3_c1 (val);
147 CREATE INDEX p1_c3_c2_val1 ON p1_c3_c2 (val);
148 CREATE INDEX p1_c3_c2_val2 ON p1_c3_c2 (val);
149 CREATE INDEX p1_c3_c2_val3 ON p1_c3_c2 (val);
150 CREATE INDEX p1_c4_val1 ON p1_c4 (val);
151 CREATE INDEX p1_c4_val2 ON p1_c4 (val);
152 CREATE INDEX p1_c4_val3 ON p1_c4 (val);
153 ANALYZE t1;
154 ANALYZE t2;
155 ANALYZE t3;
156 ANALYZE t4;
157 ANALYZE t5;
158 ANALYZE p1;
159 ANALYZE p1_c1;
160 ANALYZE p1_c2;
161 ANALYZE p2;
162 CREATE VIEW v1 AS SELECT id, val FROM t1;
163 CREATE VIEW v2 AS SELECT t1.id t1_id, t1.val t1_val, t2.id t2_id, t2.val t2_val FROM t1, t2 WHERE t1.id = t2.id;
164 CREATE VIEW v3 AS SELECT t_1.id t1_id, t_1.val t1_val, t_2.id t2_id, t_2.val t2_val FROM t1 t_1, t2 t_2 WHERE t_1.id = t_2.id;
165 CREATE VIEW v4 AS SELECT v_2.t1_id, t_3.id FROM v2 v_2, t3 t_3 WHERE v_2.t1_id = t_3.id;
166 /*
167  * The following GUC parameters need the setting of the default value to
168  * succeed in regression test.
169  */
170 CREATE VIEW settings AS
171 SELECT name, setting, category
172   FROM pg_settings
173  WHERE category LIKE 'Query Tuning%'
174     OR name = 'client_min_messages'
175  ORDER BY category, name;
176 SELECT * FROM settings;
177            name            |  setting  |                  category                   
178 ---------------------------+-----------+---------------------------------------------
179  geqo                      | on        | Query Tuning / Genetic Query Optimizer
180  geqo_effort               | 5         | Query Tuning / Genetic Query Optimizer
181  geqo_generations          | 0         | Query Tuning / Genetic Query Optimizer
182  geqo_pool_size            | 0         | Query Tuning / Genetic Query Optimizer
183  geqo_seed                 | 0         | Query Tuning / Genetic Query Optimizer
184  geqo_selection_bias       | 2         | Query Tuning / Genetic Query Optimizer
185  geqo_threshold            | 12        | Query Tuning / Genetic Query Optimizer
186  constraint_exclusion      | partition | Query Tuning / Other Planner Options
187  cursor_tuple_fraction     | 0.1       | Query Tuning / Other Planner Options
188  default_statistics_target | 100       | Query Tuning / Other Planner Options
189  from_collapse_limit       | 8         | Query Tuning / Other Planner Options
190  join_collapse_limit       | 8         | Query Tuning / Other Planner Options
191  cpu_index_tuple_cost      | 0.005     | Query Tuning / Planner Cost Constants
192  cpu_operator_cost         | 0.0025    | Query Tuning / Planner Cost Constants
193  cpu_tuple_cost            | 0.01      | Query Tuning / Planner Cost Constants
194  effective_cache_size      | 16384     | Query Tuning / Planner Cost Constants
195  random_page_cost          | 4         | Query Tuning / Planner Cost Constants
196  seq_page_cost             | 1         | Query Tuning / Planner Cost Constants
197  enable_bitmapscan         | on        | Query Tuning / Planner Method Configuration
198  enable_hashagg            | on        | Query Tuning / Planner Method Configuration
199  enable_hashjoin           | on        | Query Tuning / Planner Method Configuration
200  enable_indexscan          | on        | Query Tuning / Planner Method Configuration
201  enable_material           | on        | Query Tuning / Planner Method Configuration
202  enable_mergejoin          | on        | Query Tuning / Planner Method Configuration
203  enable_nestloop           | on        | Query Tuning / Planner Method Configuration
204  enable_seqscan            | on        | Query Tuning / Planner Method Configuration
205  enable_sort               | on        | Query Tuning / Planner Method Configuration
206  enable_tidscan            | on        | Query Tuning / Planner Method Configuration
207  client_min_messages       | notice    | Reporting and Logging / When to Log
208 (29 rows)
209