Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Implement CREATE AS SELECT in Impala

Pls help me on how to implement CREATE TABLE AS SELECT

For simple create table t1 as select * from t2; I can implement as

Create table t1 like t2;
insert into t1 as select * from t2;

But how to implement create table t1 as select c1,c2,c3 from t2;

Is there any way to implement this in impala?

like image 470
on_the_shores_of_linux_sea Avatar asked Oct 23 '13 03:10

on_the_shores_of_linux_sea


1 Answers

As mentioned in the comments, CREATE TABLE AS SELECT is supported in Impala since 1.2: documentation, JIRA ticket.

like image 144
Nickolay Avatar answered Sep 25 '22 19:09

Nickolay