Skip to content

Commit

Permalink
appent test.
Browse files Browse the repository at this point in the history
  • Loading branch information
hubgeter committed Jul 26, 2024
1 parent fb44ed0 commit 92ee1a0
Show file tree
Hide file tree
Showing 9 changed files with 376 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1871,6 +1871,19 @@ LOCATION

msck repair table test_string_dict_filter_orc;

create table test_hive_struct_add_column_orc (
`id` int,
`name` string,
`details` struct<age:int,city:string,email:string,phone:int>,
`sex` int,
`complex` array<struct<a:int,b:struct<aa:string,bb:int>>>
)
STORED AS ORC
LOCATION '/user/doris/preinstalled_data/orc_table/test_hive_struct_add_column_orc';

msck repair table test_hive_struct_add_column_orc;


show tables;


Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,206 @@
-- This file is automatically generated. You should know what you did if you want to edit this
-- !desc --
id INT Yes true \N
name TEXT Yes true \N
details STRUCT<age:INT,city:TEXT,email:TEXT,phone:INT> Yes true \N
sex INT Yes true \N
complex ARRAY<STRUCT<a:INT,b:STRUCT<aa:TEXT,bb:INT>>> Yes true \N

-- !test_1 --
1 Alice {"age": 25, "city": "New York", "email": null, "phone": null} \N \N
2 Blice {"age": 26, "city": "New York New York", "email": null, "phone": null} \N \N
3 Clice {"age": 27, "city": "New York New York New York", "email": null, "phone": null} \N \N
4 Dlice {"age": 28, "city": "New York New York New York New York", "email": null, "phone": null} \N \N
5 Elice {"age": 29, "city": "New York New York New York New York New York", "email": null, "phone": null} \N \N
11 AAlice {"age": 125, "city": "acity", "email": "[email protected]", "phone": null} \N \N
12 BBlice {"age": 126, "city": "bcity", "email": "[email protected]", "phone": null} \N \N
13 CClice {"age": 127, "city": "ccity", "email": "[email protected]", "phone": null} \N \N
14 DDlice {"age": 128, "city": "dcity", "email": "[email protected]", "phone": null} \N \N
15 EElice {"age": 129, "city": "ecity", "email": null, "phone": null} \N \N
21 Charlie {"age": 218, "city": "San Francisco", "email": "[email protected]", "phone": 123} \N \N
22 Charlie {"age": 228, "city": "San-Francisco", "email": "[email protected]", "phone": 1234} \N \N
23 Charlie {"age": 238, "city": "SanxFrancisco", "email": "[email protected]", "phone": 12345} \N \N
24 Charlie {"age": 248, "city": "San888Francisco", "email": "[email protected]", "phone": 123456} \N \N
25 Charlie {"age": 258, "city": "San0000Francisco", "email": "[email protected]", "phone": null} \N \N
31 Alice {"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456} 0 \N
32 Bob {"age": 30, "city": "Los Angeles", "email": "[email protected]", "phone": 789012} 0 \N
33 Charlie {"age": 28, "city": "San Francisco", "email": "[email protected]", "phone": 456789} 1 \N
34 David {"age": 32, "city": "Chicago", "email": "[email protected]", "phone": 987654} 0 \N
35 Eve {"age": 27, "city": "Seattle", "email": "[email protected]", "phone": null} \N \N
41 Alice {"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456} 1 [{"a": 1, "b": null}, {"a": 1, "b": null}]
42 Bob {"age": 30, "city": "Los Angeles", "email": "[email protected]", "phone": 789012} 1 [{"a": 2, "b": null}, {"a": 1, "b": null}]
43 Charlie {"age": 28, "city": "San Francisco", "email": "[email protected]", "phone": 456789} 2 [{"a": 3, "b": null}, {"a": 1, "b": null}]
44 David {"age": 32, "city": "Chicago", "email": "[email protected]", "phone": 987654} 1 [{"a": 4, "b": null}, {"a": 1, "b": null}]
45 Eve {"age": 27, "city": "Seattle", "email": "[email protected]", "phone": 654321} 2 [{"a": 5, "b": null}, {"a": 1, "b": null}]
51 Alice {"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456} 1 [{"a": 1, "b": {"aa": "foo", "bb": 100}}, {"a": 1, "b": {"aa": "foo", "bb": 100}}]
52 Bob {"age": 30, "city": "Los Angeles", "email": "[email protected]", "phone": 789012} 2 [{"a": 2, "b": {"aa": "bar", "bb": 200}}]
53 Charlie {"age": 28, "city": "San Francisco", "email": "[email protected]", "phone": 456789} 1 [{"a": 3, "b": {"aa": "baz", "bb": 300}}]
54 David {"age": 32, "city": "Chicago", "email": "[email protected]", "phone": 987654} 2 [{"a": 8, "b": {"aa": "qux", "bb": 400}}]
55 Eve {"age": 27, "city": "Seattle", "email": "[email protected]", "phone": 654321} 1 [{"a": 5, "b": {"aa": "abcd", "bb": 500}}]

-- !test_2 --
1 Alice {"age": 25, "city": "New York", "email": null, "phone": null} \N \N

-- !test_3 --
1 Alice {"age": 25, "city": "New York", "email": null, "phone": null} \N \N
2 Blice {"age": 26, "city": "New York New York", "email": null, "phone": null} \N \N
3 Clice {"age": 27, "city": "New York New York New York", "email": null, "phone": null} \N \N
4 Dlice {"age": 28, "city": "New York New York New York New York", "email": null, "phone": null} \N \N
5 Elice {"age": 29, "city": "New York New York New York New York New York", "email": null, "phone": null} \N \N
11 AAlice {"age": 125, "city": "acity", "email": "[email protected]", "phone": null} \N \N
12 BBlice {"age": 126, "city": "bcity", "email": "[email protected]", "phone": null} \N \N
13 CClice {"age": 127, "city": "ccity", "email": "[email protected]", "phone": null} \N \N
14 DDlice {"age": 128, "city": "dcity", "email": "[email protected]", "phone": null} \N \N
15 EElice {"age": 129, "city": "ecity", "email": null, "phone": null} \N \N
21 Charlie {"age": 218, "city": "San Francisco", "email": "[email protected]", "phone": 123} \N \N
22 Charlie {"age": 228, "city": "San-Francisco", "email": "[email protected]", "phone": 1234} \N \N
23 Charlie {"age": 238, "city": "SanxFrancisco", "email": "[email protected]", "phone": 12345} \N \N
24 Charlie {"age": 248, "city": "San888Francisco", "email": "[email protected]", "phone": 123456} \N \N
25 Charlie {"age": 258, "city": "San0000Francisco", "email": "[email protected]", "phone": null} \N \N
31 Alice {"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456} 0 \N
32 Bob {"age": 30, "city": "Los Angeles", "email": "[email protected]", "phone": 789012} 0 \N
33 Charlie {"age": 28, "city": "San Francisco", "email": "[email protected]", "phone": 456789} 1 \N
34 David {"age": 32, "city": "Chicago", "email": "[email protected]", "phone": 987654} 0 \N
35 Eve {"age": 27, "city": "Seattle", "email": "[email protected]", "phone": null} \N \N

-- !test_4 --
41 Alice {"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456} 1 [{"a": 1, "b": null}, {"a": 1, "b": null}]
42 Bob {"age": 30, "city": "Los Angeles", "email": "[email protected]", "phone": 789012} 1 [{"a": 2, "b": null}, {"a": 1, "b": null}]
43 Charlie {"age": 28, "city": "San Francisco", "email": "[email protected]", "phone": 456789} 2 [{"a": 3, "b": null}, {"a": 1, "b": null}]
44 David {"age": 32, "city": "Chicago", "email": "[email protected]", "phone": 987654} 1 [{"a": 4, "b": null}, {"a": 1, "b": null}]
45 Eve {"age": 27, "city": "Seattle", "email": "[email protected]", "phone": 654321} 2 [{"a": 5, "b": null}, {"a": 1, "b": null}]
51 Alice {"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456} 1 [{"a": 1, "b": {"aa": "foo", "bb": 100}}, {"a": 1, "b": {"aa": "foo", "bb": 100}}]
52 Bob {"age": 30, "city": "Los Angeles", "email": "[email protected]", "phone": 789012} 2 [{"a": 2, "b": {"aa": "bar", "bb": 200}}]
53 Charlie {"age": 28, "city": "San Francisco", "email": "[email protected]", "phone": 456789} 1 [{"a": 3, "b": {"aa": "baz", "bb": 300}}]
54 David {"age": 32, "city": "Chicago", "email": "[email protected]", "phone": 987654} 2 [{"a": 8, "b": {"aa": "qux", "bb": 400}}]
55 Eve {"age": 27, "city": "Seattle", "email": "[email protected]", "phone": 654321} 1 [{"a": 5, "b": {"aa": "abcd", "bb": 500}}]

-- !test_5 --
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N

-- !test_6 --
[{"a": 1, "b": null}, {"a": 1, "b": null}]
[{"a": 2, "b": null}, {"a": 1, "b": null}]
[{"a": 3, "b": null}, {"a": 1, "b": null}]
[{"a": 4, "b": null}, {"a": 1, "b": null}]
[{"a": 5, "b": null}, {"a": 1, "b": null}]
[{"a": 1, "b": {"aa": "foo", "bb": 100}}, {"a": 1, "b": {"aa": "foo", "bb": 100}}]
[{"a": 2, "b": {"aa": "bar", "bb": 200}}]
[{"a": 3, "b": {"aa": "baz", "bb": 300}}]
[{"a": 8, "b": {"aa": "qux", "bb": 400}}]
[{"a": 5, "b": {"aa": "abcd", "bb": 500}}]

-- !test_7 --
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N
\N

-- !test_8 --
[{"a": 1, "b": null}, {"a": 1, "b": null}]
[{"a": 2, "b": null}, {"a": 1, "b": null}]
[{"a": 3, "b": null}, {"a": 1, "b": null}]
[{"a": 4, "b": null}, {"a": 1, "b": null}]
[{"a": 5, "b": null}, {"a": 1, "b": null}]
[{"a": 1, "b": {"aa": "foo", "bb": 100}}, {"a": 1, "b": {"aa": "foo", "bb": 100}}]
[{"a": 2, "b": {"aa": "bar", "bb": 200}}]
[{"a": 3, "b": {"aa": "baz", "bb": 300}}]
[{"a": 8, "b": {"aa": "qux", "bb": 400}}]
[{"a": 5, "b": {"aa": "abcd", "bb": 500}}]

-- !test_9 --
0
0
0

-- !test_10 --
1
1
1
1
1
1
1

-- !test_11 --
2
2
2
2

-- !test_12 --
43 Charlie {"age": 28, "city": "San Francisco", "email": "[email protected]", "phone": 456789} 2 [{"a": 3, "b": null}, {"a": 1, "b": null}]
45 Eve {"age": 27, "city": "Seattle", "email": "[email protected]", "phone": 654321} 2 [{"a": 5, "b": null}, {"a": 1, "b": null}]
52 Bob {"age": 30, "city": "Los Angeles", "email": "[email protected]", "phone": 789012} 2 [{"a": 2, "b": {"aa": "bar", "bb": 200}}]
54 David {"age": 32, "city": "Chicago", "email": "[email protected]", "phone": 987654} 2 [{"a": 8, "b": {"aa": "qux", "bb": 400}}]

-- !test_13 --

-- !test_14 --
53 Charlie {"age": 28, "city": "San Francisco", "email": "[email protected]", "phone": 456789} 1 [{"a": 3, "b": {"aa": "baz", "bb": 300}}]
54 David {"age": 32, "city": "Chicago", "email": "[email protected]", "phone": 987654} 2 [{"a": 8, "b": {"aa": "qux", "bb": 400}}]

-- !test_15 --
41 Alice {"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456} 1 [{"a": 1, "b": null}, {"a": 1, "b": null}] {"a": 1, "b": null}
51 Alice {"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456} 1 [{"a": 1, "b": {"aa": "foo", "bb": 100}}, {"a": 1, "b": {"aa": "foo", "bb": 100}}] {"a": 1, "b": {"aa": "foo", "bb": 100}}

-- !test_16 --
[{"a": 2, "b": null}, {"a": 1, "b": null}]

-- !test_17 --
{"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456}
{"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456}
{"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456}

-- !test_18 --
{"age": 25, "city": "New York", "email": null, "phone": null}

-- !test_19 --
{"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456} 31
{"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456} 41
{"age": 25, "city": "New York", "email": "[email protected]", "phone": 123456} 51

-- !test_20 --
{"age": 25, "city": "New York", "email": null, "phone": null} 1

-- !test_21 --
0 3
2 4
1 7
\N 16

Loading

0 comments on commit 92ee1a0

Please sign in to comment.