فهرست منبع

Export all does not work as Hive managed table location cannot be changed (#2885)

Jira: CDPD-40785
Mahesh Balakrishnan 3 سال پیش
والد
کامیت
117353a8b0
1فایلهای تغییر یافته به همراه1 افزوده شده و 3 حذف شده
  1. 1 3
      desktop/libs/notebook/src/notebook/connectors/hiveserver2.py

+ 1 - 3
desktop/libs/notebook/src/notebook/connectors/hiveserver2.py

@@ -650,7 +650,7 @@ class HS2Api(Api):
     hql = '''
 DROP TABLE IF EXISTS `%(table)s`;
 
-CREATE TABLE `%(table)s` ROW FORMAT DELIMITED
+CREATE EXTERNAL TABLE `%(table)s` ROW FORMAT DELIMITED
      FIELDS TERMINATED BY '\\t'
      ESCAPED BY '\\\\'
      LINES TERMINATED BY '\\n'
@@ -658,8 +658,6 @@ CREATE TABLE `%(table)s` ROW FORMAT DELIMITED
      AS
 %(hql)s;
 
-ALTER TABLE `%(table)s` SET TBLPROPERTIES('EXTERNAL'='TRUE');
-
 DROP TABLE IF EXISTS `%(table)s`;
     ''' % {
       'table': _get_snippet_name(notebook, unique=True, table_format=True),