Skip to content

Commit 41b93ee

Browse files
jiaqizhomy-ship-it
authored andcommitted
Fix icw test from "Cherry-Pick CUBE grouping set, predicates from subquery ..."
1 parent 5fd7ed7 commit 41b93ee

4 files changed

Lines changed: 15 additions & 46 deletions

File tree

src/test/regress/expected/dpe_optimizer.out

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -278,6 +278,7 @@ explain (costs off, timing off, summary off, analyze) select * from pt where exi
278278
Extra Text: (seg1) Hash chain length 1.0 avg, 1 max, using 2 of 262144 buckets.
279279
-> Dynamic Seq Scan on pt (actual rows=8 loops=1)
280280
Number of partitions to scan: 6
281+
Filter: (NOT (ptid IS NULL))
281282
Partitions scanned: Avg 2.0 x 3 workers. Max 2 parts (seg0).
282283
-> Hash (actual rows=2 loops=1)
283284
Buckets: 262144 Batches: 1 Memory Usage: 2049kB
@@ -293,7 +294,7 @@ explain (costs off, timing off, summary off, analyze) select * from pt where exi
293294
-> Seq Scan on t (actual rows=2 loops=1)
294295
Filter: (t1 = ('hello'::text || (tid)::text))
295296
Optimizer: Pivotal Optimizer (GPORCA)
296-
(21 rows)
297+
(22 rows)
297298

298299
select * from pt where exists (select 1 from t where tid = ptid and t1 = 'hello' || tid);
299300
dist | pt1 | pt2 | pt3 | ptid

src/test/regress/expected/groupingsets_optimizer.out

Lines changed: 7 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1670,24 +1670,20 @@ explain (costs off)
16701670
Sort Key: share0_ref3.b
16711671
-> Redistribute Motion 3:3 (slice2; segments: 3)
16721672
Hash Key: share0_ref3.b
1673-
-> Partial GroupAggregate
1673+
-> Streaming Partial HashAggregate
16741674
Group Key: share0_ref3.b
1675-
-> Sort
1676-
Sort Key: share0_ref3.b
1677-
-> Shared Scan (share slice:id 2:0)
1678-
-> GroupAggregate
1675+
-> Shared Scan (share slice:id 2:0)
1676+
-> HashAggregate
16791677
Group Key: share0_ref4.a
1680-
-> Sort
1681-
Sort Key: share0_ref4.a
1682-
-> Shared Scan (share slice:id 1:0)
1678+
-> Shared Scan (share slice:id 1:0)
16831679
-> Result
16841680
-> Redistribute Motion 1:3 (slice3)
16851681
-> Finalize Aggregate
16861682
-> Gather Motion 3:1 (slice4; segments: 3)
16871683
-> Partial Aggregate
16881684
-> Shared Scan (share slice:id 4:0)
16891685
Optimizer: Pivotal Optimizer (GPORCA)
1690-
(40 rows)
1686+
(36 rows)
16911687

16921688
select a, b, sum(v.x)
16931689
from (values (1),(2)) v(x), gstest_data(v.x)
@@ -2388,23 +2384,7 @@ create table gs_group_1 as
23882384
select g1000, g100, g10, sum(g::numeric), count(*), max(g::text) from
23892385
(select g%1000 as g1000, g%100 as g100, g%10 as g10, g
23902386
from generate_series(0,199999) g) s
2391-
group by cube (g1000,g100,g10);
2392-
NOTICE: Table doesn't have 'DISTRIBUTED BY' clause -- Using column(s) named 'g1000' as the Greenplum Database data distribution key for this table.
2393-
HINT: The 'DISTRIBUTED BY' clause determines the distribution of data. Make sure column(s) chosen are the optimal data distribution key to minimize skew.
2394-
set jit_above_cost to default;
2395-
create table gs_group_2 as
2396-
select g1000, g100, g10, sum(g::numeric), count(*), max(g::text) from
2397-
(select g/20 as g1000, g/200 as g100, g/2000 as g10, g
2398-
from generate_series(0,19999) g) s
2399-
group by cube (g1000,g100,g10);
2400-
NOTICE: Table doesn't have 'DISTRIBUTED BY' clause -- Using column(s) named 'g1000' as the Greenplum Database data distribution key for this table.
2401-
HINT: The 'DISTRIBUTED BY' clause determines the distribution of data. Make sure column(s) chosen are the optimal data distribution key to minimize skew.
2402-
create table gs_group_3 as
2403-
select g100, g10, array_agg(g) as a, count(*) as c, max(g::text) as m from
2404-
(select g/200 as g100, g/2000 as g10, g
2405-
from generate_series(0,19999) g) s
2406-
group by grouping sets (g100,g10);
2407-
NOTICE: Table doesn't have 'DISTRIBUTED BY' clause. Creating a NULL policy entry.
2387+
group by cube (g1000,g100,g10) distributed by (g1000);
24082388
-- Produce results with hash aggregation.
24092389
set enable_hashagg = true;
24102390
set enable_sort = false;
@@ -2449,23 +2429,8 @@ create table gs_hash_1 as
24492429
select g1000, g100, g10, sum(g::numeric), count(*), max(g::text) from
24502430
(select g%1000 as g1000, g%100 as g100, g%10 as g10, g
24512431
from generate_series(0,199999) g) s
2452-
group by cube (g1000,g100,g10);
2453-
NOTICE: Table doesn't have 'DISTRIBUTED BY' clause -- Using column(s) named 'g1000' as the Greenplum Database data distribution key for this table.
2454-
HINT: The 'DISTRIBUTED BY' clause determines the distribution of data. Make sure column(s) chosen are the optimal data distribution key to minimize skew.
2432+
group by cube (g1000,g100,g10) distributed by (g1000);
24552433
set jit_above_cost to default;
2456-
create table gs_hash_2 as
2457-
select g1000, g100, g10, sum(g::numeric), count(*), max(g::text) from
2458-
(select g/20 as g1000, g/200 as g100, g/2000 as g10, g
2459-
from generate_series(0,19999) g) s
2460-
group by cube (g1000,g100,g10);
2461-
NOTICE: Table doesn't have 'DISTRIBUTED BY' clause -- Using column(s) named 'g1000' as the Greenplum Database data distribution key for this table.
2462-
HINT: The 'DISTRIBUTED BY' clause determines the distribution of data. Make sure column(s) chosen are the optimal data distribution key to minimize skew.
2463-
create table gs_hash_3 as
2464-
select g100, g10, array_agg(g) as a, count(*) as c, max(g::text) as m from
2465-
(select g/200 as g100, g/2000 as g10, g
2466-
from generate_series(0,19999) g) s
2467-
group by grouping sets (g100,g10);
2468-
NOTICE: Table doesn't have 'DISTRIBUTED BY' clause. Creating a NULL policy entry.
24692434
set enable_sort = true;
24702435
set work_mem to default;
24712436
WARNING: "work_mem": setting is deprecated, and may be removed in a future release.

src/test/regress/expected/join_optimizer.out

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1933,8 +1933,9 @@ where exists(select * from tenk1 b
19331933
-> Seq Scan on int4_tbl
19341934
-> Index Scan using tenk1_thous_tenthous on tenk1 tenk1_1
19351935
Index Cond: (tenthous = int4_tbl.f1)
1936+
Filter: (NOT (twothousand IS NULL))
19361937
Optimizer: Pivotal Optimizer (GPORCA)
1937-
(18 rows)
1938+
(19 rows)
19381939

19391940
--
19401941
-- More complicated constructs

src/test/regress/expected/window_optimizer.out

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3794,11 +3794,11 @@ WINDOW fwd AS (
37943794
INFO: GPORCA failed to produce a plan, falling back to planner
37953795
DETAIL: GPDB Expression type: Query Parameter not supported in DXL
37963796
INFO: GPORCA failed to produce a plan, falling back to planner
3797-
DETAIL: GPDB Expression type: Query Parameter not supported in DXL
3798-
INFO: GPORCA failed to produce a plan, falling back to planner
37993797
DETAIL: Feature not supported: SIRV functions
38003798
INFO: GPORCA failed to produce a plan, falling back to planner
38013799
DETAIL: Feature not supported: SIRV functions
3800+
INFO: GPORCA failed to produce a plan, falling back to planner
3801+
DETAIL: GPDB Expression type: Query Parameter not supported in DXL
38023802
eq1 | eq2 | eq3
38033803
-----+-----+-----
38043804
t | t | t
@@ -4321,6 +4321,8 @@ EXPLAIN (costs off) SELECT * FROM pg_temp.f(2);
43214321
(2 rows)
43224322

43234323
SELECT * FROM pg_temp.f(2);
4324+
INFO: GPORCA failed to produce a plan, falling back to planner
4325+
DETAIL: GPDB Expression type: Query Parameter not supported in DXL
43244326
f
43254327
---------
43264328
{1,2,3}

0 commit comments

Comments
 (0)