forked from apache/doris
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[test](migrate) move 2 cases from p2 to p0 (apache#36787)
- test_external_credit_data - test_upper_case_column_name Only move the hive related cases, the iceberg related will be done in next PR
- Loading branch information
1 parent
1d2c42c
commit a89bb1d
Showing
39 changed files
with
685 additions
and
170 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
...r/thirdparties/docker-compose/hive/scripts/data/multi_catalog/datev2_csv/create_table.hql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
create database if not exists multi_catalog; | ||
|
||
use multi_catalog; | ||
|
||
CREATE external TABLE `datev2_csv`( | ||
`id` int, | ||
`day` date) | ||
ROW FORMAT SERDE | ||
'org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe' | ||
STORED AS INPUTFORMAT | ||
'org.apache.hadoop.mapred.TextInputFormat' | ||
OUTPUTFORMAT | ||
'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat' | ||
LOCATION | ||
'/user/doris/suites/multi_catalog/datev2_csv' | ||
TBLPROPERTIES ( | ||
'transient_lastDdlTime'='1688118691'); | ||
|
||
msck repair table datev2_csv; | ||
|
Binary file added
BIN
+184 Bytes
docker/thirdparties/docker-compose/hive/scripts/data/multi_catalog/datev2_csv/data.tar.gz
Binary file not shown.
13 changes: 13 additions & 0 deletions
13
docker/thirdparties/docker-compose/hive/scripts/data/multi_catalog/datev2_csv/run.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/bin/bash | ||
set -x | ||
|
||
CUR_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd)" | ||
|
||
## mkdir and put data to hdfs | ||
cd "${CUR_DIR}" && rm -rf data/ && tar xzf data.tar.gz | ||
hadoop fs -mkdir -p /user/doris/suites/multi_catalog/ | ||
hadoop fs -put "${CUR_DIR}"/data/* /user/doris/suites/multi_catalog/ | ||
|
||
# create table | ||
hive -f "${CUR_DIR}/create_table.hql" | ||
|
20 changes: 20 additions & 0 deletions
20
...r/thirdparties/docker-compose/hive/scripts/data/multi_catalog/datev2_orc/create_table.hql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
create database if not exists multi_catalog; | ||
|
||
use multi_catalog; | ||
|
||
CREATE external TABLE `datev2_orc`( | ||
`id` int, | ||
`day` date) | ||
ROW FORMAT SERDE | ||
'org.apache.hadoop.hive.ql.io.orc.OrcSerde' | ||
STORED AS INPUTFORMAT | ||
'org.apache.hadoop.hive.ql.io.orc.OrcInputFormat' | ||
OUTPUTFORMAT | ||
'org.apache.hadoop.hive.ql.io.orc.OrcOutputFormat' | ||
LOCATION | ||
'/user/doris/suites/multi_catalog/datev2_orc' | ||
TBLPROPERTIES ( | ||
'transient_lastDdlTime'='1688118707'); | ||
|
||
msck repair table datev2_orc; | ||
|
Binary file added
BIN
+459 Bytes
docker/thirdparties/docker-compose/hive/scripts/data/multi_catalog/datev2_orc/data.tar.gz
Binary file not shown.
13 changes: 13 additions & 0 deletions
13
docker/thirdparties/docker-compose/hive/scripts/data/multi_catalog/datev2_orc/run.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/bin/bash | ||
set -x | ||
|
||
CUR_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd)" | ||
|
||
## mkdir and put data to hdfs | ||
cd "${CUR_DIR}" && rm -rf data/ && tar xzf data.tar.gz | ||
hadoop fs -mkdir -p /user/doris/suites/multi_catalog/ | ||
hadoop fs -put "${CUR_DIR}"/data/* /user/doris/suites/multi_catalog/ | ||
|
||
# create table | ||
hive -f "${CUR_DIR}"/create_table.hql | ||
|
20 changes: 20 additions & 0 deletions
20
...irdparties/docker-compose/hive/scripts/data/multi_catalog/datev2_parquet/create_table.hql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
create database if not exists multi_catalog; | ||
|
||
use multi_catalog; | ||
|
||
CREATE external TABLE `datev2_parquet`( | ||
`id` int, | ||
`day` date) | ||
ROW FORMAT SERDE | ||
'org.apache.hadoop.hive.ql.io.parquet.serde.ParquetHiveSerDe' | ||
STORED AS INPUTFORMAT | ||
'org.apache.hadoop.hive.ql.io.parquet.MapredParquetInputFormat' | ||
OUTPUTFORMAT | ||
'org.apache.hadoop.hive.ql.io.parquet.MapredParquetOutputFormat' | ||
LOCATION | ||
'/user/doris/suites/multi_catalog/datev2_parquet' | ||
TBLPROPERTIES ( | ||
'transient_lastDdlTime'='1688118725'); | ||
|
||
msck repair table datev2_parquet; | ||
|
Binary file added
BIN
+384 Bytes
...er/thirdparties/docker-compose/hive/scripts/data/multi_catalog/datev2_parquet/data.tar.gz
Binary file not shown.
13 changes: 13 additions & 0 deletions
13
docker/thirdparties/docker-compose/hive/scripts/data/multi_catalog/datev2_parquet/run.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/bin/bash | ||
set -x | ||
|
||
CUR_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd)" | ||
|
||
## mkdir and put data to hdfs | ||
cd "${CUR_DIR}" && rm -rf data/ && tar xzf data.tar.gz | ||
hadoop fs -mkdir -p /user/doris/suites/multi_catalog/ | ||
hadoop fs -put "${CUR_DIR}"/data/* /user/doris/suites/multi_catalog/ | ||
|
||
# create table | ||
hive -f "${CUR_DIR}"/create_table.hql | ||
|
21 changes: 21 additions & 0 deletions
21
...rties/docker-compose/hive/scripts/data/multi_catalog/hive_upper_case_orc/create_table.hql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
create database if not exists multi_catalog; | ||
use multi_catalog; | ||
|
||
CREATE TABLE `hive_upper_case_orc`( | ||
`id` int, | ||
`name` string) | ||
ROW FORMAT SERDE | ||
'org.apache.hadoop.hive.ql.io.orc.OrcSerde' | ||
STORED AS INPUTFORMAT | ||
'org.apache.hadoop.hive.ql.io.orc.OrcInputFormat' | ||
OUTPUTFORMAT | ||
'org.apache.hadoop.hive.ql.io.orc.OrcOutputFormat' | ||
LOCATION | ||
'/user/doris/suites/multi_catalog/hive_upper_case_orc' | ||
TBLPROPERTIES ( | ||
'spark.sql.create.version'='3.2.1', | ||
'spark.sql.sources.schema'='{"type":"struct","fields":[{"name":"ID","type":"integer","nullable":true,"metadata":{}},{"name":"NAME","type":"string","nullable":true,"metadata":{}}]}', | ||
'transient_lastDdlTime'='1674189057'); | ||
|
||
msck repair table hive_upper_case_orc; | ||
|
Binary file added
BIN
+521 Bytes
...irdparties/docker-compose/hive/scripts/data/multi_catalog/hive_upper_case_orc/data.tar.gz
Binary file not shown.
13 changes: 13 additions & 0 deletions
13
...er/thirdparties/docker-compose/hive/scripts/data/multi_catalog/hive_upper_case_orc/run.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/bin/bash | ||
set -x | ||
|
||
CUR_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd)" | ||
|
||
## mkdir and put data to hdfs | ||
cd "${CUR_DIR}" && rm -rf data/ && tar xzf data.tar.gz | ||
hadoop fs -mkdir -p /user/doris/suites/multi_catalog/ | ||
hadoop fs -put "${CUR_DIR}"/data/* /user/doris/suites/multi_catalog/ | ||
|
||
# create table | ||
hive -f "${CUR_DIR}"/create_table.hql | ||
|
21 changes: 21 additions & 0 deletions
21
...s/docker-compose/hive/scripts/data/multi_catalog/hive_upper_case_parquet/create_table.hql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
create database if not exists multi_catalog; | ||
use multi_catalog; | ||
|
||
CREATE TABLE `hive_upper_case_parquet`( | ||
`id` int, | ||
`name` string) | ||
ROW FORMAT SERDE | ||
'org.apache.hadoop.hive.ql.io.parquet.serde.ParquetHiveSerDe' | ||
STORED AS INPUTFORMAT | ||
'org.apache.hadoop.hive.ql.io.parquet.MapredParquetInputFormat' | ||
OUTPUTFORMAT | ||
'org.apache.hadoop.hive.ql.io.parquet.MapredParquetOutputFormat' | ||
LOCATION | ||
'/user/doris/suites/multi_catalog/hive_upper_case_parquet' | ||
TBLPROPERTIES ( | ||
'spark.sql.create.version'='3.2.1', | ||
'spark.sql.sources.schema'='{"type":"struct","fields":[{"name":"ID","type":"integer","nullable":true,"metadata":{}},{"name":"NAME","type":"string","nullable":true,"metadata":{}}]}', | ||
'transient_lastDdlTime'='1674189051'); | ||
|
||
msck repair table hive_upper_case_parquet; | ||
|
Binary file added
BIN
+690 Bytes
...arties/docker-compose/hive/scripts/data/multi_catalog/hive_upper_case_parquet/data.tar.gz
Binary file not shown.
13 changes: 13 additions & 0 deletions
13
...hirdparties/docker-compose/hive/scripts/data/multi_catalog/hive_upper_case_parquet/run.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/bin/bash | ||
set -x | ||
|
||
CUR_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd)" | ||
|
||
## mkdir and put data to hdfs | ||
cd "${CUR_DIR}" && rm -rf data/ && tar xzf data.tar.gz | ||
hadoop fs -mkdir -p /user/doris/suites/multi_catalog/ | ||
hadoop fs -put "${CUR_DIR}"/data/* /user/doris/suites/multi_catalog/ | ||
|
||
# create table | ||
hive -f "${CUR_DIR}"/create_table.hql | ||
|
31 changes: 31 additions & 0 deletions
31
...s/docker-compose/hive/scripts/data/multi_catalog/parquet_lz4_compression/create_table.hql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
create database if not exists multi_catalog; | ||
use multi_catalog; | ||
|
||
CREATE TABLE `parquet_lz4_compression`( | ||
`col_int` int, | ||
`col_smallint` smallint, | ||
`col_tinyint` tinyint, | ||
`col_bigint` bigint, | ||
`col_float` float, | ||
`col_double` double, | ||
`col_boolean` boolean, | ||
`col_string` string, | ||
`col_char` char(10), | ||
`col_varchar` varchar(25), | ||
`col_date` date, | ||
`col_timestamp` timestamp, | ||
`col_decimal` decimal(10,2)) | ||
ROW FORMAT SERDE | ||
'org.apache.hadoop.hive.ql.io.parquet.serde.ParquetHiveSerDe' | ||
STORED AS INPUTFORMAT | ||
'org.apache.hadoop.hive.ql.io.parquet.MapredParquetInputFormat' | ||
OUTPUTFORMAT | ||
'org.apache.hadoop.hive.ql.io.parquet.MapredParquetOutputFormat' | ||
LOCATION | ||
'/user/doris/suites/multi_catalog/parquet_lz4_compression' | ||
TBLPROPERTIES ( | ||
'parquet.compression'='LZ4', | ||
'transient_lastDdlTime'='1700723950'); | ||
|
||
msck repair table parquet_lz4_compression; | ||
|
Binary file added
BIN
+11.1 KB
...arties/docker-compose/hive/scripts/data/multi_catalog/parquet_lz4_compression/data.tar.gz
Binary file not shown.
13 changes: 13 additions & 0 deletions
13
...hirdparties/docker-compose/hive/scripts/data/multi_catalog/parquet_lz4_compression/run.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/bin/bash | ||
set -x | ||
|
||
CUR_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd)" | ||
|
||
## mkdir and put data to hdfs | ||
cd "${CUR_DIR}" && rm -rf data/ && tar xzf data.tar.gz | ||
hadoop fs -mkdir -p /user/doris/suites/multi_catalog/ | ||
hadoop fs -put "${CUR_DIR}"/data/* /user/doris/suites/multi_catalog/ | ||
|
||
# create table | ||
hive -f "${CUR_DIR}"/create_table.hql | ||
|
31 changes: 31 additions & 0 deletions
31
...s/docker-compose/hive/scripts/data/multi_catalog/parquet_lzo_compression/create_table.hql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
create database if not exists multi_catalog; | ||
use multi_catalog; | ||
|
||
CREATE TABLE `parquet_lzo_compression`( | ||
`col_int` int, | ||
`col_smallint` smallint, | ||
`col_tinyint` tinyint, | ||
`col_bigint` bigint, | ||
`col_float` float, | ||
`col_double` double, | ||
`col_boolean` boolean, | ||
`col_string` string, | ||
`col_char` char(10), | ||
`col_varchar` varchar(25), | ||
`col_date` date, | ||
`col_timestamp` timestamp, | ||
`col_decimal` decimal(10,2)) | ||
ROW FORMAT SERDE | ||
'org.apache.hadoop.hive.ql.io.parquet.serde.ParquetHiveSerDe' | ||
STORED AS INPUTFORMAT | ||
'org.apache.hadoop.hive.ql.io.parquet.MapredParquetInputFormat' | ||
OUTPUTFORMAT | ||
'org.apache.hadoop.hive.ql.io.parquet.MapredParquetOutputFormat' | ||
LOCATION | ||
'/user/doris/suites/multi_catalog/parquet_lzo_compression' | ||
TBLPROPERTIES ( | ||
'parquet.compression'='LZO', | ||
'transient_lastDdlTime'='1701173147'); | ||
|
||
msck repair table parquet_lzo_compression; | ||
|
Binary file added
BIN
+27.8 KB
...arties/docker-compose/hive/scripts/data/multi_catalog/parquet_lzo_compression/data.tar.gz
Binary file not shown.
13 changes: 13 additions & 0 deletions
13
...hirdparties/docker-compose/hive/scripts/data/multi_catalog/parquet_lzo_compression/run.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/bin/bash | ||
set -x | ||
|
||
CUR_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd)" | ||
|
||
## mkdir and put data to hdfs | ||
cd "${CUR_DIR}" && rm -rf data/ && tar xzf data.tar.gz | ||
hadoop fs -mkdir -p /user/doris/suites/multi_catalog/ | ||
hadoop fs -put "${CUR_DIR}"/data/* /user/doris/suites/multi_catalog/ | ||
|
||
# create table | ||
hive -f "${CUR_DIR}"/create_table.hql | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 22 additions & 0 deletions
22
...rdparties/docker-compose/hive/scripts/data/multi_catalog/test_compress_partitioned/run.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
#!/bin/bash | ||
set -x | ||
|
||
CUR_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd)" | ||
|
||
if [[ ! -d "${CUR_DIR}/data" ]]; then | ||
echo "${CUR_DIR}/data does not exist" | ||
cd "${CUR_DIR}" && rm -f data.tar.gz \ | ||
&& curl -O https://s3BucketName.s3Endpoint/regression/datalake/pipeline_data/multi_catalog/test_compress_partitioned/data.tar.gz \ | ||
&& tar xzf data.tar.gz | ||
cd - | ||
else | ||
echo "${CUR_DIR}/data exist, continue !" | ||
fi | ||
|
||
## mkdir and put data to hdfs | ||
hadoop fs -mkdir -p /user/doris/suites/multi_catalog/ | ||
hadoop fs -put "${CUR_DIR}"/data/* /user/doris/suites/multi_catalog/ | ||
|
||
# create table | ||
hive -f "${CUR_DIR}"/create_table.hql | ||
|
Oops, something went wrong.