mirror of
https://github.com/apache/impala.git
synced 2026-01-07 18:02:33 -05:00
IMPALA-2974: Use Type.toSql() instead of toString() in ALTER TABLE CHANGE COLUMN.
Change-Id: I140bdea755e44d3f2ceb4a8f5e288faaddaa963f Reviewed-on: http://gerrit.cloudera.org:8080/2285 Reviewed-by: Alex Behm <alex.behm@cloudera.com> Tested-by: Internal Jenkins
This commit is contained in:
committed by
Harrison Sheinblatt
parent
d5ecaeca73
commit
5c0e1fa1e8
@@ -183,6 +183,28 @@ describe t2
|
||||
string,string,string
|
||||
====
|
||||
---- QUERY
|
||||
# IMPALA-2974: Change a single column to a complex type.
|
||||
alter table t2 change column c c array<struct<f1:decimal(10,2)>>;
|
||||
describe t2;
|
||||
---- RESULTS
|
||||
'a','int','Int Col'
|
||||
'b','struct<\n f1:array<int>,\n f2:map<string,struct<\n f1:bigint\n >>\n>',''
|
||||
'c','array<struct<\n f1:decimal(10,2)\n>>',''
|
||||
---- TYPES
|
||||
string,string,string
|
||||
====
|
||||
---- QUERY
|
||||
# Change a single complex-typed column to a scalar type.
|
||||
alter table t2 change column c c varchar(20);
|
||||
describe t2;
|
||||
---- RESULTS
|
||||
'a','int','Int Col'
|
||||
'b','struct<\n f1:array<int>,\n f2:map<string,struct<\n f1:bigint\n >>\n>',''
|
||||
'c','varchar(20)',''
|
||||
---- TYPES
|
||||
string,string,string
|
||||
====
|
||||
---- QUERY
|
||||
create external table jointbl_test like functional.jointbl
|
||||
---- RESULTS
|
||||
====
|
||||
|
||||
Reference in New Issue
Block a user