mirror of
https://git.postgresql.org/git/postgresql.git
synced 2025-01-24 18:55:04 +08:00
Add missing COSTS OFF to EXPLAIN commands in rowsecurity.sql.
Commit e5e11c8cc
added a bunch of EXPLAIN statements without COSTS OFF
to the regression tests. This is contrary to project policy since it
results in unnecessary platform dependencies in the output (it's just
luck that we didn't get buildfarm failures from it). Per gripe from
Mike Wilson.
This commit is contained in:
parent
d37b816dc9
commit
654218138b
@ -1680,42 +1680,42 @@ EXPLAIN (COSTS OFF) SELECT * FROM z1 WHERE f_leak(b);
|
||||
(4 rows)
|
||||
|
||||
PREPARE plancache_test AS SELECT * FROM z1 WHERE f_leak(b);
|
||||
EXPLAIN EXECUTE plancache_test;
|
||||
QUERY PLAN
|
||||
---------------------------------------------------------------
|
||||
Subquery Scan on z1 (cost=0.00..29.11 rows=2 width=36)
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test;
|
||||
QUERY PLAN
|
||||
-------------------------------
|
||||
Subquery Scan on z1
|
||||
Filter: f_leak(z1.b)
|
||||
-> Seq Scan on z1 z1_1 (cost=0.00..29.05 rows=6 width=36)
|
||||
-> Seq Scan on z1 z1_1
|
||||
Filter: ((a % 2) = 0)
|
||||
(4 rows)
|
||||
|
||||
PREPARE plancache_test2 AS WITH q AS (SELECT * FROM z1 WHERE f_leak(b)) SELECT * FROM q,z2;
|
||||
EXPLAIN EXECUTE plancache_test2;
|
||||
QUERY PLAN
|
||||
-----------------------------------------------------------------------
|
||||
Nested Loop (cost=29.11..86.78 rows=2540 width=72)
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test2;
|
||||
QUERY PLAN
|
||||
---------------------------------------
|
||||
Nested Loop
|
||||
CTE q
|
||||
-> Subquery Scan on z1 (cost=0.00..29.11 rows=2 width=36)
|
||||
-> Subquery Scan on z1
|
||||
Filter: f_leak(z1.b)
|
||||
-> Seq Scan on z1 z1_1 (cost=0.00..29.05 rows=6 width=36)
|
||||
-> Seq Scan on z1 z1_1
|
||||
Filter: ((a % 2) = 0)
|
||||
-> CTE Scan on q (cost=0.00..0.04 rows=2 width=36)
|
||||
-> Materialize (cost=0.00..29.05 rows=1270 width=36)
|
||||
-> Seq Scan on z2 (cost=0.00..22.70 rows=1270 width=36)
|
||||
-> CTE Scan on q
|
||||
-> Materialize
|
||||
-> Seq Scan on z2
|
||||
(9 rows)
|
||||
|
||||
PREPARE plancache_test3 AS WITH q AS (SELECT * FROM z2) SELECT * FROM q,z1 WHERE f_leak(z1.b);
|
||||
EXPLAIN EXECUTE plancache_test3;
|
||||
QUERY PLAN
|
||||
---------------------------------------------------------------------------
|
||||
Nested Loop (cost=22.70..108.97 rows=2540 width=72)
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test3;
|
||||
QUERY PLAN
|
||||
-------------------------------------------
|
||||
Nested Loop
|
||||
CTE q
|
||||
-> Seq Scan on z2 (cost=0.00..22.70 rows=1270 width=36)
|
||||
-> CTE Scan on q (cost=0.00..25.40 rows=1270 width=36)
|
||||
-> Materialize (cost=0.00..29.12 rows=2 width=36)
|
||||
-> Subquery Scan on z1 (cost=0.00..29.11 rows=2 width=36)
|
||||
-> Seq Scan on z2
|
||||
-> CTE Scan on q
|
||||
-> Materialize
|
||||
-> Subquery Scan on z1
|
||||
Filter: f_leak(z1.b)
|
||||
-> Seq Scan on z1 z1_1 (cost=0.00..29.05 rows=6 width=36)
|
||||
-> Seq Scan on z1 z1_1
|
||||
Filter: ((a % 2) = 0)
|
||||
(9 rows)
|
||||
|
||||
@ -1738,40 +1738,40 @@ EXPLAIN (COSTS OFF) SELECT * FROM z1 WHERE f_leak(b);
|
||||
Filter: ((a % 2) = 0)
|
||||
(4 rows)
|
||||
|
||||
EXPLAIN EXECUTE plancache_test;
|
||||
QUERY PLAN
|
||||
---------------------------------------------------------------
|
||||
Subquery Scan on z1 (cost=0.00..29.11 rows=2 width=36)
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test;
|
||||
QUERY PLAN
|
||||
-------------------------------
|
||||
Subquery Scan on z1
|
||||
Filter: f_leak(z1.b)
|
||||
-> Seq Scan on z1 z1_1 (cost=0.00..29.05 rows=6 width=36)
|
||||
-> Seq Scan on z1 z1_1
|
||||
Filter: ((a % 2) = 0)
|
||||
(4 rows)
|
||||
|
||||
EXPLAIN EXECUTE plancache_test2;
|
||||
QUERY PLAN
|
||||
-----------------------------------------------------------------------
|
||||
Nested Loop (cost=29.11..86.78 rows=2540 width=72)
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test2;
|
||||
QUERY PLAN
|
||||
---------------------------------------
|
||||
Nested Loop
|
||||
CTE q
|
||||
-> Subquery Scan on z1 (cost=0.00..29.11 rows=2 width=36)
|
||||
-> Subquery Scan on z1
|
||||
Filter: f_leak(z1.b)
|
||||
-> Seq Scan on z1 z1_1 (cost=0.00..29.05 rows=6 width=36)
|
||||
-> Seq Scan on z1 z1_1
|
||||
Filter: ((a % 2) = 0)
|
||||
-> CTE Scan on q (cost=0.00..0.04 rows=2 width=36)
|
||||
-> Materialize (cost=0.00..29.05 rows=1270 width=36)
|
||||
-> Seq Scan on z2 (cost=0.00..22.70 rows=1270 width=36)
|
||||
-> CTE Scan on q
|
||||
-> Materialize
|
||||
-> Seq Scan on z2
|
||||
(9 rows)
|
||||
|
||||
EXPLAIN EXECUTE plancache_test3;
|
||||
QUERY PLAN
|
||||
---------------------------------------------------------------------------
|
||||
Nested Loop (cost=22.70..108.97 rows=2540 width=72)
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test3;
|
||||
QUERY PLAN
|
||||
-------------------------------------------
|
||||
Nested Loop
|
||||
CTE q
|
||||
-> Seq Scan on z2 (cost=0.00..22.70 rows=1270 width=36)
|
||||
-> CTE Scan on q (cost=0.00..25.40 rows=1270 width=36)
|
||||
-> Materialize (cost=0.00..29.12 rows=2 width=36)
|
||||
-> Subquery Scan on z1 (cost=0.00..29.11 rows=2 width=36)
|
||||
-> Seq Scan on z2
|
||||
-> CTE Scan on q
|
||||
-> Materialize
|
||||
-> Subquery Scan on z1
|
||||
Filter: f_leak(z1.b)
|
||||
-> Seq Scan on z1 z1_1 (cost=0.00..29.05 rows=6 width=36)
|
||||
-> Seq Scan on z1 z1_1
|
||||
Filter: ((a % 2) = 0)
|
||||
(9 rows)
|
||||
|
||||
@ -1794,40 +1794,40 @@ EXPLAIN (COSTS OFF) SELECT * FROM z1 WHERE f_leak(b);
|
||||
Filter: ((a % 2) = 1)
|
||||
(4 rows)
|
||||
|
||||
EXPLAIN EXECUTE plancache_test;
|
||||
QUERY PLAN
|
||||
---------------------------------------------------------------
|
||||
Subquery Scan on z1 (cost=0.00..29.11 rows=2 width=36)
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test;
|
||||
QUERY PLAN
|
||||
-------------------------------
|
||||
Subquery Scan on z1
|
||||
Filter: f_leak(z1.b)
|
||||
-> Seq Scan on z1 z1_1 (cost=0.00..29.05 rows=6 width=36)
|
||||
-> Seq Scan on z1 z1_1
|
||||
Filter: ((a % 2) = 1)
|
||||
(4 rows)
|
||||
|
||||
EXPLAIN EXECUTE plancache_test2;
|
||||
QUERY PLAN
|
||||
-----------------------------------------------------------------------
|
||||
Nested Loop (cost=29.11..86.78 rows=2540 width=72)
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test2;
|
||||
QUERY PLAN
|
||||
---------------------------------------
|
||||
Nested Loop
|
||||
CTE q
|
||||
-> Subquery Scan on z1 (cost=0.00..29.11 rows=2 width=36)
|
||||
-> Subquery Scan on z1
|
||||
Filter: f_leak(z1.b)
|
||||
-> Seq Scan on z1 z1_1 (cost=0.00..29.05 rows=6 width=36)
|
||||
-> Seq Scan on z1 z1_1
|
||||
Filter: ((a % 2) = 1)
|
||||
-> CTE Scan on q (cost=0.00..0.04 rows=2 width=36)
|
||||
-> Materialize (cost=0.00..29.05 rows=1270 width=36)
|
||||
-> Seq Scan on z2 (cost=0.00..22.70 rows=1270 width=36)
|
||||
-> CTE Scan on q
|
||||
-> Materialize
|
||||
-> Seq Scan on z2
|
||||
(9 rows)
|
||||
|
||||
EXPLAIN EXECUTE plancache_test3;
|
||||
QUERY PLAN
|
||||
---------------------------------------------------------------------------
|
||||
Nested Loop (cost=22.70..108.97 rows=2540 width=72)
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test3;
|
||||
QUERY PLAN
|
||||
-------------------------------------------
|
||||
Nested Loop
|
||||
CTE q
|
||||
-> Seq Scan on z2 (cost=0.00..22.70 rows=1270 width=36)
|
||||
-> CTE Scan on q (cost=0.00..25.40 rows=1270 width=36)
|
||||
-> Materialize (cost=0.00..29.12 rows=2 width=36)
|
||||
-> Subquery Scan on z1 (cost=0.00..29.11 rows=2 width=36)
|
||||
-> Seq Scan on z2
|
||||
-> CTE Scan on q
|
||||
-> Materialize
|
||||
-> Subquery Scan on z1
|
||||
Filter: f_leak(z1.b)
|
||||
-> Seq Scan on z1 z1_1 (cost=0.00..29.05 rows=6 width=36)
|
||||
-> Seq Scan on z1 z1_1
|
||||
Filter: ((a % 2) = 1)
|
||||
(9 rows)
|
||||
|
||||
@ -1850,40 +1850,40 @@ EXPLAIN (COSTS OFF) SELECT * FROM z1 WHERE f_leak(b);
|
||||
Filter: ((a % 2) = 1)
|
||||
(4 rows)
|
||||
|
||||
EXPLAIN EXECUTE plancache_test;
|
||||
QUERY PLAN
|
||||
---------------------------------------------------------------
|
||||
Subquery Scan on z1 (cost=0.00..29.11 rows=2 width=36)
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test;
|
||||
QUERY PLAN
|
||||
-------------------------------
|
||||
Subquery Scan on z1
|
||||
Filter: f_leak(z1.b)
|
||||
-> Seq Scan on z1 z1_1 (cost=0.00..29.05 rows=6 width=36)
|
||||
-> Seq Scan on z1 z1_1
|
||||
Filter: ((a % 2) = 1)
|
||||
(4 rows)
|
||||
|
||||
EXPLAIN EXECUTE plancache_test2;
|
||||
QUERY PLAN
|
||||
-----------------------------------------------------------------------
|
||||
Nested Loop (cost=29.11..86.78 rows=2540 width=72)
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test2;
|
||||
QUERY PLAN
|
||||
---------------------------------------
|
||||
Nested Loop
|
||||
CTE q
|
||||
-> Subquery Scan on z1 (cost=0.00..29.11 rows=2 width=36)
|
||||
-> Subquery Scan on z1
|
||||
Filter: f_leak(z1.b)
|
||||
-> Seq Scan on z1 z1_1 (cost=0.00..29.05 rows=6 width=36)
|
||||
-> Seq Scan on z1 z1_1
|
||||
Filter: ((a % 2) = 1)
|
||||
-> CTE Scan on q (cost=0.00..0.04 rows=2 width=36)
|
||||
-> Materialize (cost=0.00..29.05 rows=1270 width=36)
|
||||
-> Seq Scan on z2 (cost=0.00..22.70 rows=1270 width=36)
|
||||
-> CTE Scan on q
|
||||
-> Materialize
|
||||
-> Seq Scan on z2
|
||||
(9 rows)
|
||||
|
||||
EXPLAIN EXECUTE plancache_test3;
|
||||
QUERY PLAN
|
||||
---------------------------------------------------------------------------
|
||||
Nested Loop (cost=22.70..108.97 rows=2540 width=72)
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test3;
|
||||
QUERY PLAN
|
||||
-------------------------------------------
|
||||
Nested Loop
|
||||
CTE q
|
||||
-> Seq Scan on z2 (cost=0.00..22.70 rows=1270 width=36)
|
||||
-> CTE Scan on q (cost=0.00..25.40 rows=1270 width=36)
|
||||
-> Materialize (cost=0.00..29.12 rows=2 width=36)
|
||||
-> Subquery Scan on z1 (cost=0.00..29.11 rows=2 width=36)
|
||||
-> Seq Scan on z2
|
||||
-> CTE Scan on q
|
||||
-> Materialize
|
||||
-> Subquery Scan on z1
|
||||
Filter: f_leak(z1.b)
|
||||
-> Seq Scan on z1 z1_1 (cost=0.00..29.05 rows=6 width=36)
|
||||
-> Seq Scan on z1 z1_1
|
||||
Filter: ((a % 2) = 1)
|
||||
(9 rows)
|
||||
|
||||
|
@ -650,37 +650,37 @@ SELECT * FROM z1 WHERE f_leak(b);
|
||||
EXPLAIN (COSTS OFF) SELECT * FROM z1 WHERE f_leak(b);
|
||||
|
||||
PREPARE plancache_test AS SELECT * FROM z1 WHERE f_leak(b);
|
||||
EXPLAIN EXECUTE plancache_test;
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test;
|
||||
|
||||
PREPARE plancache_test2 AS WITH q AS (SELECT * FROM z1 WHERE f_leak(b)) SELECT * FROM q,z2;
|
||||
EXPLAIN EXECUTE plancache_test2;
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test2;
|
||||
|
||||
PREPARE plancache_test3 AS WITH q AS (SELECT * FROM z2) SELECT * FROM q,z1 WHERE f_leak(z1.b);
|
||||
EXPLAIN EXECUTE plancache_test3;
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test3;
|
||||
|
||||
SET ROLE rls_regress_group1;
|
||||
SELECT * FROM z1 WHERE f_leak(b);
|
||||
EXPLAIN (COSTS OFF) SELECT * FROM z1 WHERE f_leak(b);
|
||||
|
||||
EXPLAIN EXECUTE plancache_test;
|
||||
EXPLAIN EXECUTE plancache_test2;
|
||||
EXPLAIN EXECUTE plancache_test3;
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test;
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test2;
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test3;
|
||||
|
||||
SET SESSION AUTHORIZATION rls_regress_user2;
|
||||
SELECT * FROM z1 WHERE f_leak(b);
|
||||
EXPLAIN (COSTS OFF) SELECT * FROM z1 WHERE f_leak(b);
|
||||
|
||||
EXPLAIN EXECUTE plancache_test;
|
||||
EXPLAIN EXECUTE plancache_test2;
|
||||
EXPLAIN EXECUTE plancache_test3;
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test;
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test2;
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test3;
|
||||
|
||||
SET ROLE rls_regress_group2;
|
||||
SELECT * FROM z1 WHERE f_leak(b);
|
||||
EXPLAIN (COSTS OFF) SELECT * FROM z1 WHERE f_leak(b);
|
||||
|
||||
EXPLAIN EXECUTE plancache_test;
|
||||
EXPLAIN EXECUTE plancache_test2;
|
||||
EXPLAIN EXECUTE plancache_test3;
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test;
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test2;
|
||||
EXPLAIN (COSTS OFF) EXECUTE plancache_test3;
|
||||
|
||||
--
|
||||
-- Views should follow policy for view owner.
|
||||
|
Loading…
Reference in New Issue
Block a user