You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@carbondata.apache.org by "Vandana Yadav (JIRA)" <ji...@apache.org> on 2017/11/10 07:06:06 UTC

[jira] [Updated] (CARBONDATA-1696) Incorrect output on presto CLI after rename table query on table

     [ https://issues.apache.org/jira/browse/CARBONDATA-1696?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Vandana Yadav updated CARBONDATA-1696:
--------------------------------------
    Affects Version/s: 1.3.0
           Attachment: 2000_UniqData.csv
          Environment: spark 2.1
             Priority: Minor  (was: Major)
          Description: 
Incorrect output on presto CLI after rename table query on table

Steps to Reproduce:
On Beeline:
1) Create Table:
CREATE TABLE uniqdata (CUST_ID bigint,CUST_NAME String,ACTIVE_EMUI_VERSION string, DOB timestamp, DOJ timestamp, BIGINT_COLUMN1 bigint,BIGINT_COLUMN2 bigint,DECIMAL_COLUMN1 decimal(30,10), DECIMAL_COLUMN2 decimal(36,10),Double_COLUMN1 double, Double_COLUMN2 double,INTEGER_COLUMN1 int) STORED BY 'org.apache.carbondata.format' TBLPROPERTIES ("TABLE_BLOCKSIZE"= "256 MB");

2) Load Data
LOAD DATA INPATH 'hdfs://localhost:54310/Data/uniqdata/2000_UniqData.csv' into table uniqdata OPTIONS('DELIMITER'=',' , 'QUOTECHAR'='"','BAD_RECORDS_ACTION'='FORCE','FILEHEADER'='CUST_ID,CUST_NAME,ACTIVE_EMUI_VERSION,DOB,DOJ,BIGINT_COLUMN1,BIGINT_COLUMN2,DECIMAL_COLUMN1,DECIMAL_COLUMN2,Double_COLUMN1,Double_COLUMN2,INTEGER_COLUMN1');

3) Execute Query:
a)alter table uniqdata rename to newuniqdata;
b) desc uniqdata;
output:

Error: org.apache.spark.sql.catalyst.analysis.NoSuchTableException: Table or view 'uniqdata' not found in database 'newpresto'; (state=,code=0)

On presto CLI:
1) Execute Query:
a) desc uniqdata;

2) Expected Output: It should display an error saying table or view not found, similar to beeline result.

3) Actual Result:
      Column        |      Type      | Extra | Comment 
---------------------+----------------+-------+---------
 cust_id             | bigint         |       |         
 cust_name           | varchar        |       |         
 active_emui_version | varchar        |       |         
 dob                 | timestamp      |       |         
 doj                 | timestamp      |       |         
 bigint_column1      | bigint         |       |         
 bigint_column2      | bigint         |       |         
 decimal_column1     | decimal(30,10) |       |         
 decimal_column2     | decimal(36,10) |       |         
 double_column1      | double         |       |         
 double_column2      | double         |       |         
 integer_column1     | integer        |       |         
(12 rows)

          Component/s: presto-integration
              Summary: Incorrect output on presto CLI after rename table query on table  (was: +)

> Incorrect output on presto CLI after rename table query on table
> ----------------------------------------------------------------
>
>                 Key: CARBONDATA-1696
>                 URL: https://issues.apache.org/jira/browse/CARBONDATA-1696
>             Project: CarbonData
>          Issue Type: Bug
>          Components: presto-integration
>    Affects Versions: 1.3.0
>         Environment: spark 2.1
>            Reporter: Vandana Yadav
>            Priority: Minor
>         Attachments: 2000_UniqData.csv
>
>
> Incorrect output on presto CLI after rename table query on table
> Steps to Reproduce:
> On Beeline:
> 1) Create Table:
> CREATE TABLE uniqdata (CUST_ID bigint,CUST_NAME String,ACTIVE_EMUI_VERSION string, DOB timestamp, DOJ timestamp, BIGINT_COLUMN1 bigint,BIGINT_COLUMN2 bigint,DECIMAL_COLUMN1 decimal(30,10), DECIMAL_COLUMN2 decimal(36,10),Double_COLUMN1 double, Double_COLUMN2 double,INTEGER_COLUMN1 int) STORED BY 'org.apache.carbondata.format' TBLPROPERTIES ("TABLE_BLOCKSIZE"= "256 MB");
> 2) Load Data
> LOAD DATA INPATH 'hdfs://localhost:54310/Data/uniqdata/2000_UniqData.csv' into table uniqdata OPTIONS('DELIMITER'=',' , 'QUOTECHAR'='"','BAD_RECORDS_ACTION'='FORCE','FILEHEADER'='CUST_ID,CUST_NAME,ACTIVE_EMUI_VERSION,DOB,DOJ,BIGINT_COLUMN1,BIGINT_COLUMN2,DECIMAL_COLUMN1,DECIMAL_COLUMN2,Double_COLUMN1,Double_COLUMN2,INTEGER_COLUMN1');
> 3) Execute Query:
> a)alter table uniqdata rename to newuniqdata;
> b) desc uniqdata;
> output:
> Error: org.apache.spark.sql.catalyst.analysis.NoSuchTableException: Table or view 'uniqdata' not found in database 'newpresto'; (state=,code=0)
> On presto CLI:
> 1) Execute Query:
> a) desc uniqdata;
> 2) Expected Output: It should display an error saying table or view not found, similar to beeline result.
> 3) Actual Result:
>       Column        |      Type      | Extra | Comment 
> ---------------------+----------------+-------+---------
>  cust_id             | bigint         |       |         
>  cust_name           | varchar        |       |         
>  active_emui_version | varchar        |       |         
>  dob                 | timestamp      |       |         
>  doj                 | timestamp      |       |         
>  bigint_column1      | bigint         |       |         
>  bigint_column2      | bigint         |       |         
>  decimal_column1     | decimal(30,10) |       |         
>  decimal_column2     | decimal(36,10) |       |         
>  double_column1      | double         |       |         
>  double_column2      | double         |       |         
>  integer_column1     | integer        |       |         
> (12 rows)



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)