@@ -14,22 +14,19 @@ AS upgrade_test_old_citus_version_lt_14_0;
1414\endif
1515SET citus.shard_replication_factor TO 1;
1616SET client_min_messages TO WARNING;
17- DROP SCHEMA IF EXISTS post_14_upgrade CASCADE;
18- CREATE SCHEMA post_14_upgrade ;
19- SET search_path = post_14_upgrade ;
17+ DROP SCHEMA IF EXISTS "Post_14_!'upgrade" CASCADE;
18+ CREATE SCHEMA "Post_14_!'upgrade" ;
19+ SET search_path = "Post_14_!'upgrade" ;
2020create table test_c1_tbl_1(text_col text);
2121create table test_c1_tbl_2(text_col text);
2222create table test_c1_tbl_3(text_col text);
2323create table test_c2_tbl_1(text_col text collate "en-x-icu");
2424create table test_c2_tbl_2(text_col text collate "en-x-icu");
2525create table test_c2_tbl_3(text_col text collate "en-x-icu");
26- create table test_c3_tbl_1(text_col text collate "C");
27- create table test_c3_tbl_2(text_col text collate "C");
28- create table test_c3_tbl_3(text_col text collate "C");
2926-- also some tables with weird names
30- create table "test_c4_Tbl_ !'@#_1" (text_col text collate "en_US.utf8 ");
31- create table "test_c4_Tbl_ !'@#_2" (text_col text collate "en_US.utf8 ");
32- create table "test_c4_Tbl_ !'@#_3" (text_col text collate "en_US.utf8 ");
27+ create table "test_c3_Tbl_ !'@#_1" (text_col text collate "C ");
28+ create table "test_c3_Tbl_ !'@#_2" (text_col text collate "C ");
29+ create table "test_c3_Tbl_ !'@#_3" (text_col text collate "C ");
3330select create_distributed_table('test_c1_tbl_1', 'text_col', colocate_with => 'none');
3431 create_distributed_table
3532---------------------------------------------------------------------
@@ -66,37 +63,19 @@ select create_distributed_table('test_c2_tbl_3', 'text_col', colocate_with => 't
6663
6764(1 row)
6865
69- select create_distributed_table('test_c3_tbl_1 ', 'text_col', colocate_with => 'none');
66+ SELECT create_distributed_table('"test_c3_Tbl_!''@#_1" ', 'text_col', colocate_with => 'none');
7067 create_distributed_table
7168---------------------------------------------------------------------
7269
7370(1 row)
7471
75- select create_distributed_table('test_c3_tbl_2' , 'text_col', colocate_with => 'test_c3_tbl_1 ');
72+ SELECT create_distributed_table('"test_c3_Tbl_!''@#_2"' , 'text_col', colocate_with => '"test_c3_Tbl_!''@#_1" ');
7673 create_distributed_table
7774---------------------------------------------------------------------
7875
7976(1 row)
8077
81- select create_distributed_table('test_c3_tbl_3', 'text_col', colocate_with => 'test_c3_tbl_1');
82- create_distributed_table
83- ---------------------------------------------------------------------
84-
85- (1 row)
86-
87- SELECT create_distributed_table('"test_c4_Tbl_!''@#_1"', 'text_col', colocate_with => 'none');
88- create_distributed_table
89- ---------------------------------------------------------------------
90-
91- (1 row)
92-
93- SELECT create_distributed_table('"test_c4_Tbl_!''@#_2"', 'text_col', colocate_with => '"test_c4_Tbl_!''@#_1"');
94- create_distributed_table
95- ---------------------------------------------------------------------
96-
97- (1 row)
98-
99- SELECT create_distributed_table('"test_c4_Tbl_!''@#_3"', 'text_col', colocate_with => '"test_c4_Tbl_!''@#_1"');
78+ SELECT create_distributed_table('"test_c3_Tbl_!''@#_3"', 'text_col', colocate_with => '"test_c3_Tbl_!''@#_1"');
10079 create_distributed_table
10180---------------------------------------------------------------------
10281
@@ -106,12 +85,12 @@ SELECT create_distributed_table('"test_c4_Tbl_!''@#_3"', 'text_col', colocate_wi
10685-- to be so by providing colocate_with=>'none' for the first table in each
10786-- group.
10887select result as colocationids_different from run_command_on_all_nodes($$
109- select count(distinct(colocationid)) = 4
88+ select count(distinct(colocationid)) = 3
11089 from pg_dist_partition
11190 join pg_class on (logicalrelid = pg_class.oid)
11291 join pg_namespace on (relnamespace = pg_namespace.oid)
11392 join pg_dist_colocation using (colocationid)
114- where pg_namespace.nspname = 'post_14_upgrade '
93+ where pg_namespace.nspname = 'Post_14_!''upgrade '
11594$$);
11695 colocationids_different
11796---------------------------------------------------------------------
@@ -131,7 +110,7 @@ select result as colocation_group_collations_same from run_command_on_all_nodes(
131110 join pg_class on (logicalrelid = pg_class.oid)
132111 join pg_namespace on (relnamespace = pg_namespace.oid)
133112 join pg_dist_colocation using (colocationid)
134- where pg_namespace.nspname = 'post_14_upgrade '
113+ where pg_namespace.nspname = 'Post_14_!''upgrade '
135114$$);
136115 colocation_group_collations_same
137116---------------------------------------------------------------------
0 commit comments