diff options
author | Liang-Chi Hsieh <simonh@tw.ibm.com> | 2016-04-14 11:08:08 -0700 |
---|---|---|
committer | Andrew Or <andrew@databricks.com> | 2016-04-14 11:08:08 -0700 |
commit | 28efdd3fd789fa2ebed5be03b36ca0f682e37669 (patch) | |
tree | 0c354cfde01c380c63d27b507a702c30616f6ce6 /sql/hive/compatibility/src/test | |
parent | c971aee40d806ed02d3d6a5cc478b63654052e54 (diff) | |
download | spark-28efdd3fd789fa2ebed5be03b36ca0f682e37669.tar.gz spark-28efdd3fd789fa2ebed5be03b36ca0f682e37669.tar.bz2 spark-28efdd3fd789fa2ebed5be03b36ca0f682e37669.zip |
[SPARK-14592][SQL] Native support for CREATE TABLE LIKE DDL command
## What changes were proposed in this pull request?
JIRA: https://issues.apache.org/jira/browse/SPARK-14592
This patch adds native support for DDL command `CREATE TABLE LIKE`.
The SQL syntax is like:
CREATE TABLE table_name LIKE existing_table
CREATE TABLE IF NOT EXISTS table_name LIKE existing_table
## How was this patch tested?
`HiveDDLCommandSuite`. `HiveQuerySuite` already tests `CREATE TABLE LIKE`.
Author: Liang-Chi Hsieh <simonh@tw.ibm.com>
This patch had conflicts when merged, resolved by
Committer: Andrew Or <andrew@databricks.com>
Closes #12362 from viirya/create-table-like.
Diffstat (limited to 'sql/hive/compatibility/src/test')
-rw-r--r-- | sql/hive/compatibility/src/test/scala/org/apache/spark/sql/hive/execution/HiveCompatibilitySuite.scala | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sql/hive/compatibility/src/test/scala/org/apache/spark/sql/hive/execution/HiveCompatibilitySuite.scala b/sql/hive/compatibility/src/test/scala/org/apache/spark/sql/hive/execution/HiveCompatibilitySuite.scala index a45d180464..989e68aebe 100644 --- a/sql/hive/compatibility/src/test/scala/org/apache/spark/sql/hive/execution/HiveCompatibilitySuite.scala +++ b/sql/hive/compatibility/src/test/scala/org/apache/spark/sql/hive/execution/HiveCompatibilitySuite.scala @@ -416,6 +416,9 @@ class HiveCompatibilitySuite extends HiveQueryFileTest with BeforeAndAfter { "skewjoinopt18", "skewjoinopt9", + // This test tries to create a table like with TBLPROPERTIES clause, which we don't support. + "create_like_tbl_props", + // Index commands are not supported "drop_index", "drop_index_removes_partition_dirs", @@ -537,7 +540,6 @@ class HiveCompatibilitySuite extends HiveQueryFileTest with BeforeAndAfter { "count", "cp_mj_rc", "create_insert_outputformat", - "create_like_tbl_props", "create_nested_type", "create_struct_table", "create_view_translate", |