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
create table part (a int, b int) partition by range (b);
31
35
NOTICE: Table doesn't have 'DISTRIBUTED BY' clause -- Using column named 'a' as the Apache Cloudberry data distribution key for this table.
32
36
HINT: The 'DISTRIBUTED BY' clause determines the distribution of data. Make sure column(s) chosen are the optimal data distribution key to minimize skew.
33
-
create external table p1_e (a int, b int) location ('file://@hostname@@abs_srcdir@/data/part1.csv') format 'csv';
34
-
create external table p2_e (a int, b int) location ('file://@hostname@@abs_srcdir@/data/part2.csv') format 'csv';
37
+
create external table p1_e (a int, b int) location (:'part1_file') format 'csv';
38
+
create external table p2_e (a int, b int) location (:'part2_file') format 'csv';
35
39
alter table part attach partition p1_e for values from (0) to (10);
36
40
NOTICE: partition constraints are not validated when attaching a readable external table
37
41
alter table part attach partition p2_e for values from (10) to (19);
@@ -420,8 +424,9 @@ explain select * from part where b > 22;
420
424
alter table part add partition exch1 start(60) end (70);
421
425
alter table part add partition exch2 start(70) end (80);
422
426
-- exchange with external tables
423
-
create external web table p3_e (a int, b int) execute 'cat > @abs_srcdir@/data/part-ext.csv' format 'csv' (delimiter as '|' null as 'null' escape as ' ');
424
-
create writable external web table p4_e (a int, b int) execute 'cat > @abs_srcdir@/data/part-ext.csv' format 'csv' (delimiter as '|' null as 'null' escape as ' ');
create external web table p3_e (a int, b int) execute :'part_ext_file' format 'csv' (delimiter as '|' null as 'null' escape as ' ');
429
+
create writable external web table p4_e (a int, b int) execute :'part_ext_file' format 'csv' (delimiter as '|' null as 'null' escape as ' ');
425
430
-- allow exchange readable external table
426
431
alter table part exchange partition exch1 with table p3_e;
427
432
NOTICE: partition constraints are not validated when attaching a readable external table
@@ -438,8 +443,8 @@ OPTIONS ( filename '/does/not/exist.csv', format 'csv');
438
443
-- exchange works, but no error checking like for external tables
439
444
alter table part exchange partition exch2 with table ft3;
440
445
-- same tests for attach partition
441
-
create external web table p5_e (a int, b int) execute 'cat > @abs_srcdir@/data/part-ext.csv' format 'csv' (delimiter as '|' null as 'null' escape as ' ');
442
-
create writable external web table p6_e (a int, b int) execute 'cat > @abs_srcdir@/data/part-ext.csv' format 'csv' (delimiter as '|' null as 'null' escape as ' ');
446
+
create external web table p5_e (a int, b int) execute :'part_ext_file' format 'csv' (delimiter as '|' null as 'null' escape as ' ');
447
+
create writable external web table p6_e (a int, b int) execute :'part_ext_file' format 'csv' (delimiter as '|' null as 'null' escape as ' ');
443
448
-- allow attach readable external table
444
449
alter table part attach partition p5_e for values from (80) to (90);
445
450
NOTICE: partition constraints are not validated when attaching a readable external table
@@ -258,13 +258,13 @@ ALTER FUNCTION foofunc_exec_on_all_segments() OWNER TO test_psql_de_role;
258
258
CREATE FUNCTION foofunc_exec_on_initplan() RETURNS setof int AS 'SELECT 1' LANGUAGE SQL EXECUTE ON INITPLAN;
259
259
ALTER FUNCTION foofunc_exec_on_initplan() OWNER TO test_psql_de_role;
260
260
\df+ foofunc_exec_on_*
261
-
List of functions
262
-
Schema | Name | Result data type | Argument data types | Type | Data access | Execute on | Volatility | Parallel | Owner | Security | Access privileges | Language | Source code | Description
Schema | Name | Result data type | Argument data types | Type | Data access | Execute on | Volatility | Parallel | Owner | Security | Access privileges | Language | Internal name | Description
0 commit comments