carbondata-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Anurag Srivastava (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CARBONDATA-422) [Bad Records]Select query failed with "NullPointerException" after data-load with options as MAXCOLUMN and BAD_RECORDS_ACTION
Date Wed, 21 Dec 2016 12:22:58 GMT

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

Anurag Srivastava commented on CARBONDATA-422:
----------------------------------------------

Hello SOURYAKANTA DWIVEDY ,

I have tested your same query with the latest build and get the result :

Quert : 

Result : 

!https://issues.apache.org/jira/secure/attachment/12844241/Screenshot2.png!

Could you please verify this with latest build and close the bug?

> [Bad Records]Select query failed with "NullPointerException" after data-load with options
as MAXCOLUMN and BAD_RECORDS_ACTION
> -----------------------------------------------------------------------------------------------------------------------------
>
>                 Key: CARBONDATA-422
>                 URL: https://issues.apache.org/jira/browse/CARBONDATA-422
>             Project: CarbonData
>          Issue Type: Bug
>          Components: data-query
>    Affects Versions: 0.1.1-incubating
>         Environment: 3 node Cluster
>            Reporter: SOURYAKANTA DWIVEDY
>            Priority: Minor
>         Attachments: Screenshot2.png
>
>
> Description : Select query failed with "NullPointerException" after data-load with options
as MAXCOLUMN and BAD_RECORDS_ACTION
> Steps:
> 1. Create table
> 2. Load data into table with BAD_RECORDS_ACTION option [ Create Table -- columns -9 ,CSV
coulmn - 10 , Header - 9]
> 3. Do select * query ,it will pass
>  4. Then Load data into table with BAD_RECORDS_ACTION and MAXCOLUMN option [ Create Table
-- columns -9 ,CSV coulmn - 10 , Header - 9,MAXCOLUMNS -- 9]
> 5. Do select * query ,it will fail with "NullPointerException"
> Log :- 
> -------
> 0: jdbc:hive2://ha-cluster/default> create table emp3(ID int,Name string,DOJ timestamp,Designation
string,Salary double,Dept string,DOB timestamp,Addr string,Gender string) STORED BY 'org.apache.carbondata.format';
> +---------+--+
> | result |
> +---------+--+
> +---------+--+
> No rows selected (0.589 seconds)
> 0: jdbc:hive2://ha-cluster/default> LOAD DATA inpath 'hdfs://hacluster/chetan/emp11.csv'
into table emp3 options('DELIMITER'=',', 'QUOTECHAR'='"','FILEHEADER'='ID,Name,DOJ,Designation,Salary,Dept,DOB,Addr,Gender',
'BAD_RECORDS_ACTION'='FORCE');
> +---------+--+
> | Result |
> +---------+--+
> +---------+--+
> No rows selected (2.415 seconds)
> 0: jdbc:hive2://ha-cluster/default> select * from emp3;
> +-------+-------+-------+--------------+----------+-------+-------+------------+---------+--+
> | id | name | doj | designation | salary | dept | dob | addr | gender |
> +-------+-------+-------+--------------+----------+-------+-------+------------+---------+--+
> | NULL | NULL | NULL | NULL | NULL | NULL | NULL | NULL | NULL |
> | 1 | AAA | NULL | Trainee | 10000.0 | IT | NULL | Pune | Male |
> | 2 | BBB | NULL | SE | 30000.0 | NW | NULL | Bangalore | Female |
> | 3 | CCC | NULL | SSE | 40000.0 | DATA | NULL | Mumbai | Female |
> | 4 | DDD | NULL | TL | 60000.0 | OPER | NULL | Delhi | Male |
> | 5 | EEE | NULL | STL | 80000.0 | MAIN | NULL | Chennai | Female |
> | 6 | FFF | NULL | Trainee | 10000.0 | IT | NULL | Pune | Male |
> | 7 | GGG | NULL | SE | 30000.0 | NW | NULL | Bangalore | Female |
> | 8 | HHH | NULL | SSE | 40000.0 | DATA | NULL | Mumbai | Female |
> | 9 | III | NULL | TL | 60000.0 | OPER | NULL | Delhi | Male |
> | 10 | JJJ | NULL | STL | 80000.0 | MAIN | NULL | Chennai | Female |
> | NULL | Name | NULL | Designation | NULL | Dept | NULL | Addr | Gender |
> +-------+-------+-------+--------------+----------+-------+-------+------------+---------+--+
> 12 rows selected (0.418 seconds)
> 0: jdbc:hive2://ha-cluster/default> LOAD DATA inpath 'hdfs://hacluster/chetan/emp11.csv'
into table emp3 options('DELIMITER'=',', 'QUOTECHAR'='"','FILEHEADER'='ID,Name,DOJ,Designation,Salary,Dept,DOB,Addr,Gender','MAXCOLUMNS'='9',
'BAD_RECORDS_ACTION'='FORCE');
> +---------+--+
> | Result |
> +---------+--+
> +---------+--+
> No rows selected (1.424 seconds)
> 0: jdbc:hive2://ha-cluster/default> select * from emp3;
> Error: java.io.IOException: java.lang.NullPointerException (state=,code=0)
> 0: jdbc:hive2://ha-cluster/default>



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message