mirror of
https://github.com/apache/impala.git
synced 2026-01-26 21:02:23 -05:00
This change modifies the output of the SHOW TABLE STATS and SHOW PARTITIONS for Kudu tables. - PARTITIONS: the #Row column has been removed - TABLE STATS: instead of showing partition informations it returns a resultset similar to HDFS table stats, #Rows, #Partitions, Size, Format and Location Example outputs can be seen in the doc changes. Testing: * kudu_stats.test is modified to verify the new result set * kudu_partition_ddl.test is modified to verify the new partitions style * Updated unit test with the new error message Change-Id: Ice4b8df65f0a53fe14b8fbe35d82c9887ab9a041 Reviewed-on: http://gerrit.cloudera.org:8080/15199 Reviewed-by: Thomas Tauber-Marshall <tmarshall@cloudera.com> Tested-by: Impala Public Jenkins <impala-public-jenkins@cloudera.com>
55 lines
1.6 KiB
Plaintext
55 lines
1.6 KiB
Plaintext
====
|
|
---- QUERY
|
|
create table simple (id int primary key, name string, valf float, vali bigint)
|
|
partition by range (partition values < 10, partition 10 <= values < 30,
|
|
partition 30 <= values) stored as kudu tblproperties('kudu.num_tablet_replicas' = '1')
|
|
---- RESULTS
|
|
'Table has been created.'
|
|
====
|
|
---- QUERY
|
|
# Tests the SHOW TABLE STATS output without stats computed
|
|
show table stats simple;
|
|
---- RESULTS
|
|
-1,3,regex:.*,'KUDU',regex:.*
|
|
---- TYPES
|
|
BIGINT,BIGINT,STRING,STRING,STRING
|
|
---- LABELS
|
|
#Rows,#Partitions,Size,Format,Location
|
|
====
|
|
---- QUERY
|
|
# Tests the SHOW TABLE STATS output after stats computed
|
|
compute stats simple;
|
|
show table stats simple;
|
|
---- RESULTS
|
|
0,3,regex:.*,'KUDU',regex:.*
|
|
---- TYPES
|
|
BIGINT,BIGINT,STRING,STRING,STRING
|
|
---- LABELS
|
|
#Rows,#Partitions,Size,Format,Location
|
|
====
|
|
---- QUERY
|
|
# Tests the SHOW PARTITIONS output
|
|
show partitions simple;
|
|
---- RESULTS
|
|
'','8000000A',regex:.*?:\d+,1
|
|
'8000000A','8000001E',regex:.*?:\d+,1
|
|
'8000001E','',regex:.*?:\d+,1
|
|
---- TYPES
|
|
STRING,STRING,STRING,INT
|
|
---- LABELS
|
|
Start Key,Stop Key,Leader Replica,#Replicas
|
|
====
|
|
---- QUERY
|
|
# IMPALA-3373: Computing stats on a Kudu table lead to duplicate columns shown for the
|
|
# table.
|
|
compute stats simple;
|
|
describe simple;
|
|
---- RESULTS
|
|
'id','int','','true','false','','AUTO_ENCODING','DEFAULT_COMPRESSION','0'
|
|
'name','string','','false','true','','AUTO_ENCODING','DEFAULT_COMPRESSION','0'
|
|
'valf','float','','false','true','','AUTO_ENCODING','DEFAULT_COMPRESSION','0'
|
|
'vali','bigint','','false','true','','AUTO_ENCODING','DEFAULT_COMPRESSION','0'
|
|
---- TYPES
|
|
STRING,STRING,STRING,STRING,STRING,STRING,STRING,STRING,STRING
|
|
====
|