Skip to content

Commit

Permalink
[test](tvf) append tvf read hive_text file regression case. (apache#2…
Browse files Browse the repository at this point in the history
  • Loading branch information
hubgeter authored and 胥剑旭 committed Dec 14, 2023
1 parent 627f7a4 commit 9b3325c
Show file tree
Hide file tree
Showing 2 changed files with 97 additions and 0 deletions.
41 changes: 41 additions & 0 deletions regression-test/data/external_table_p0/tvf/test_s3_tvf.out
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,44 @@
4 doris4 \N
5 doris5 15

-- !select_4 --
12 abcdef 1.23
12313 kkkkkk 5.77
123456 abcdef 1.2
126 abcdef 1.25
13 abcdef 1.24
156 ahef 1.26
323456 oooodef 1.27
5456 abadsasf 1.28
723456 text 1.3
823456 hive 1.32
923456 helloworld 1.89

-- !select_5 --
12 abcdef 1.23
12313 kkkkkk 5.77
123456 abcdef 1.2
126 abcdef 1.25
13 abcdef 1.24
156 ahef 1.26
323456 oooodef 1.27
5456 abadsasf 1.28
723456 text 1.3
823456 hive 1.32
923456 helloworld 1.89

-- !select_6 --
12313 kkkkkk 5.77
923456 helloworld 1.89

-- !select_7 --
12313 kkkkkk 5.77
123456 abcdef 1.2
126 abcdef 1.25
156 ahef 1.26
323456 oooodef 1.27
5456 abadsasf 1.28
723456 text 1.3
823456 hive 1.32
923456 helloworld 1.89

56 changes: 56 additions & 0 deletions regression-test/suites/external_table_p0/tvf/test_s3_tvf.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -117,4 +117,60 @@ suite("test_s3_tvf", "p0") {
"""
} finally {
}

try {
order_qt_select_4 """ SELECT * FROM S3 (
"uri" = "https://${bucket}.${s3_endpoint}/regression/tvf/test_hive_text.text",
"s3.access_key"= "${ak}",
"s3.secret_key" = "${sk}",
"format" = "hive_text",
"use_path_style" = "true",
"region" = "${region}"
) order by c1,c2,c3;
"""
} finally {
}

try {
order_qt_select_5 """ SELECT * FROM S3 (
"uri" = "https://${bucket}.${s3_endpoint}/regression/tvf/test_hive_text.text",
"s3.access_key"= "${ak}",
"s3.secret_key" = "${sk}",
"format" = "hive_text",
"use_path_style" = "true",
"region" = "${region}",
"csv_schema"="k1:int;k2:string;k3:double"
) order by k1,k2,k3;
"""
} finally {
}

try {
order_qt_select_6 """ SELECT * FROM S3 (
"uri" = "https://${bucket}.${s3_endpoint}/regression/tvf/test_hive_text.text",
"s3.access_key"= "${ak}",
"s3.secret_key" = "${sk}",
"format" = "hive_text",
"use_path_style" = "true",
"region" = "${region}",
"csv_schema"="k1:int;k2:string;k3:double"
) where k3 > 1.5 order by k3,k2,k1;
"""
} finally {
}

try {
order_qt_select_7 """ SELECT * FROM S3 (
"uri" = "https://${bucket}.${s3_endpoint}/regression/tvf/test_hive_text.text",
"s3.access_key"= "${ak}",
"s3.secret_key" = "${sk}",
"format" = "hive_text",
"use_path_style" = "true",
"region" = "${region}",
"csv_schema"="k1:int;k2:string;k3:double"
) where k1 > 100 order by k3,k2,k1;
"""
} finally {
}

}

0 comments on commit 9b3325c

Please sign in to comment.