You signed in with another tab or window.Reload to refresh your session.You signed out in another tab or window.Reload to refresh your session.You switched accounts on another tab or window.Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: expected/pathman_basic.out
+28Lines changed: 28 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -2309,6 +2309,34 @@ EXPLAIN (COSTS OFF) SELECT * FROM test.index_on_childs WHERE c1 > 100 AND c1 < 2
2309
2309
Filter: (c1 < 2500)
2310
2310
(12 rows)
2311
2311
2312
+
/* Test recursive CTE */
2313
+
create table test.recursive_cte_test_tbl(id int not null, name text not null);
2314
+
select * from create_hash_partitions('test.recursive_cte_test_tbl', 'id', 2);
2315
+
create_hash_partitions
2316
+
------------------------
2317
+
2
2318
+
(1 row)
2319
+
2320
+
insert into test.recursive_cte_test_tbl (id, name) select id, 'name'||id from generate_series(1,100) f(id);
2321
+
insert into test.recursive_cte_test_tbl (id, name) select id, 'name'||(id + 1) from generate_series(1,100) f(id);
2322
+
insert into test.recursive_cte_test_tbl (id, name) select id, 'name'||(id + 2) from generate_series(1,100) f(id);
2323
+
select * from test.recursive_cte_test_tbl where id = 5;
2324
+
id | name
2325
+
----+-------
2326
+
5 | name5
2327
+
5 | name6
2328
+
5 | name7
2329
+
(3 rows)
2330
+
2331
+
with recursive test as (select min(name) as name from test.recursive_cte_test_tbl where id = 5 union all select (select min(name) from test.recursive_cte_test_tbl where id = 5 and name > test.name) from test where name is not null) select * from test;