Skip to content

Commit aed29dc

Browse files
authored
chore(ci): try fix main ci err (#16224)
* chore(ci): try fix main ci err * fmt test
1 parent 0aed25a commit aed29dc

File tree

2 files changed

+16
-9
lines changed

2 files changed

+16
-9
lines changed

tests/suites/1_stateful/00_stage/00_0016_copy_purge_duplicated.result

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
>>>> create table t16(a int, b int)
33
>>>> drop stage if exists s16
44
>>>> create stage s16 url='fs:///tmp/00_0016/';
5+
>>>> unset global purge_duplicated_files_in_copy;
56
>>>> copy into t16 from @s16 file_format = (type = CSV) purge = true
67
i1.csv 2 0 NULL NULL
78
<<<<
@@ -13,7 +14,8 @@ i1.csv 2 0 NULL NULL
1314
duplicate file i1 into the stage
1415
put the new file i2 into the stage
1516
enable purge_duplicated_files_in_copy and copy into from location again
16-
>>>> set purge_duplicated_files_in_copy =1; copy into t16 from @s16 file_format = (type = CSV) purge = true
17+
>>>> set purge_duplicated_files_in_copy =1; select name,value,default,level from system.settings where name='purge_duplicated_files_in_copy'; copy into t16 from @s16 file_format = (type = CSV) purge = true
18+
purge_duplicated_files_in_copy 1 0 SESSION
1719
i2.csv 2 0 NULL NULL
1820
<<<<
1921
stage should be empty, the duplicated file i1 should be removed
@@ -27,7 +29,8 @@ tow new rows from new file i2 should be copied into table t16
2729
4 4
2830
put the same files into the stage
2931
enable purge_duplicated_files_in_copy and copy into from location again
30-
>>>> set purge_duplicated_files_in_copy =1; copy into t16 from @s16 file_format = (type = CSV) purge = true
32+
>>>> set purge_duplicated_files_in_copy =1;select name,value,default,level from system.settings where name='purge_duplicated_files_in_copy'; copy into t16 from @s16 file_format = (type = CSV) purge = true
33+
purge_duplicated_files_in_copy 1 0 SESSION
3134
<<<<
3235
stage should be empty
3336
>>>> list @s16
@@ -40,7 +43,8 @@ table should be unchanged
4043
4 4
4144
put the same files into the stage
4245
enable purge_duplicated_files_in_copy, but disable the purge option, then copy into from location again
43-
>>>> set purge_duplicated_files_in_copy =1; copy into t16 from @s16 file_format = (type = CSV) purge = false
46+
>>>> set purge_duplicated_files_in_copy =1; select name,value,default,level from system.settings where name='purge_duplicated_files_in_copy'; copy into t16 from @s16 file_format = (type = CSV) purge = false
47+
purge_duplicated_files_in_copy 1 0 SESSION
4448
<<<<
4549
stage should not be empty, contains i1 and i2
4650
<<<<
@@ -56,7 +60,8 @@ table should be unchanged
5660
put the same files into the stage
5761
also put the a new file into the stage
5862
enable purge_duplicated_files_in_copy, but disable the purge option, then copy into from location again
59-
>>>> set purge_duplicated_files_in_copy =1; copy into t16 from @s16 file_format = (type = CSV) purge = false
63+
>>>> set purge_duplicated_files_in_copy =1; select name,value,default,level from system.settings where name='purge_duplicated_files_in_copy'; copy into t16 from @s16 file_format = (type = CSV) purge = false
64+
purge_duplicated_files_in_copy 1 0 SESSION
6065
i3.csv 2 0 NULL NULL
6166
<<<<
6267
stage should not be empty, contains i1, i2, and i3

tests/suites/1_stateful/00_stage/00_0016_copy_purge_duplicated.sh

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ stmt "create table t16(a int, b int)"
1111

1212
stmt "drop stage if exists s16"
1313
stmt "create stage s16 url='fs:///tmp/00_0016/';"
14+
stmt "unset global purge_duplicated_files_in_copy;"
1415

1516
# setup
1617
# copy one file from test stage @s16, with purge enabled
@@ -44,7 +45,7 @@ cat << EOF > /tmp/00_0016/i2.csv
4445
EOF
4546

4647
echo "enable purge_duplicated_files_in_copy and copy into from location again"
47-
query "set purge_duplicated_files_in_copy =1; copy into t16 from @s16 file_format = (type = CSV) purge = true"
48+
query "set purge_duplicated_files_in_copy =1; select name,value,default,level from system.settings where name='purge_duplicated_files_in_copy'; copy into t16 from @s16 file_format = (type = CSV) purge = true"
4849

4950
echo "stage should be empty, the duplicated file i1 should be removed"
5051
query "list @s16"
@@ -68,7 +69,7 @@ cat << EOF > /tmp/00_0016/i2.csv
6869
EOF
6970

7071
echo "enable purge_duplicated_files_in_copy and copy into from location again"
71-
query "set purge_duplicated_files_in_copy =1; copy into t16 from @s16 file_format = (type = CSV) purge = true"
72+
query "set purge_duplicated_files_in_copy =1;select name,value,default,level from system.settings where name='purge_duplicated_files_in_copy'; copy into t16 from @s16 file_format = (type = CSV) purge = true"
7273

7374
echo "stage should be empty"
7475
query "list @s16"
@@ -93,7 +94,7 @@ cat << EOF > /tmp/00_0016/i2.csv
9394
EOF
9495

9596
echo "enable purge_duplicated_files_in_copy, but disable the purge option, then copy into from location again"
96-
query "set purge_duplicated_files_in_copy =1; copy into t16 from @s16 file_format = (type = CSV) purge = false"
97+
query "set purge_duplicated_files_in_copy =1; select name,value,default,level from system.settings where name='purge_duplicated_files_in_copy'; copy into t16 from @s16 file_format = (type = CSV) purge = false"
9798

9899
echo "stage should not be empty, contains i1 and i2"
99100
query "list @s16" | awk '{print $1}' | sort
@@ -123,7 +124,7 @@ cat << EOF > /tmp/00_0016/i3.csv
123124
EOF
124125

125126
echo "enable purge_duplicated_files_in_copy, but disable the purge option, then copy into from location again"
126-
query "set purge_duplicated_files_in_copy =1; copy into t16 from @s16 file_format = (type = CSV) purge = false"
127+
query "set purge_duplicated_files_in_copy =1; select name,value,default,level from system.settings where name='purge_duplicated_files_in_copy'; copy into t16 from @s16 file_format = (type = CSV) purge = false"
127128

128129
echo "stage should not be empty, contains i1, i2, and i3"
129130
query "list @s16" | awk '{print $1}' | sort
@@ -133,4 +134,5 @@ stmt "select * from t16 order by a"
133134

134135
# cleanup
135136
stmt "drop table if exists t16"
136-
stmt "drop stage if exists s16"
137+
stmt "drop stage if exists s16"
138+

0 commit comments

Comments
 (0)