You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@carbondata.apache.org by "Simarpreet Kaur (JIRA)" <ji...@apache.org> on 2017/09/04 07:27:00 UTC

[jira] [Commented] (CARBONDATA-1428) Incorrect Result displays while alter drop command on partitioned and non-partitioned table

    [ https://issues.apache.org/jira/browse/CARBONDATA-1428?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16152203#comment-16152203 ] 

Simarpreet Kaur commented on CARBONDATA-1428:
---------------------------------------------

I am not able to reproduce the bug. It is working fine in my system. 
No exception in alter drop command and even dropped column is not shown in describe table command.

> Incorrect Result displays while alter drop command on partitioned and non-partitioned table
> -------------------------------------------------------------------------------------------
>
>                 Key: CARBONDATA-1428
>                 URL: https://issues.apache.org/jira/browse/CARBONDATA-1428
>             Project: CarbonData
>          Issue Type: Bug
>          Components: data-query
>    Affects Versions: 1.2.0
>         Environment: spark 2.1
>            Reporter: Vandana Yadav
>         Attachments: 2000_UniqData.csv
>
>
> Incorrect Result displays while alter drop command on partitioned and non-partitioned table
> Steps to reproduce:
> 1) Create a partitioned table
> CREATE TABLE uniqdata_part1 (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) PARTITIONED BY (CUST_ID int) STORED BY 'org.apache.carbondata.format' TBLPROPERTIES ('PARTITION_TYPE'='RANGE','RANGE_INFO'='9090,9500,9800',"TABLE_BLOCKSIZE"= "256 MB")
> 2) Load data into partitioned table
> LOAD DATA INPATH 'hdfs://localhost:54310/uniqdata/2000_UniqData.csv' into table uniqdata_part1 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 drop column query on partitioned table
> ALTER TABLE uniqdata_part1 drop columns(BIGINT_COLUMN1)
> 4) Result on beeline
> Error: java.lang.RuntimeException: Alter table drop column operation failed: Column bigint_column1 does not exists in the table partition.uniqdata_part1 (state=,code=0)
> 5) Expected Result:
> it should drop the column from the partitioned table as it is not the partitioned column and existing column of the table.
> +----------------------+-----------------+----------+--+
> |       col_name       |    data_type    | comment  |
> +----------------------+-----------------+----------+--+
> | CUST_NAME            | string          | NULL     |
> | ACTIVE_EMUI_VERSION  | string          | NULL     |
> | DOB                  | timestamp       | NULL     |
> | DOJ                  | timestamp       | NULL     |
> | BIGINT_COLUMN1       | bigint          | NULL     |
> | BIGINT_COLUMN2       | bigint          | NULL     |
> | DECIMAL_COLUMN1      | decimal(30,10)  | NULL     |
> | DECIMAL_COLUMN2      | decimal(36,10)  | NULL     |
> | Double_COLUMN1       | double          | NULL     |
> | Double_COLUMN2       | double          | NULL     |
> | INTEGER_COLUMN1      | int             | NULL     |
> | CUST_ID              | int             | NULL     |



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