[
https://issues.apache.org/jira/browse/CARBONDATA-417?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15675857#comment-15675857
]
Raghunandan S commented on CARBONDATA-417:
------------------------------------------
[~mraghuvardhan] pls check this.When behavior is fail why to log the same.It
will fail the moment a bad record is encountered.
> [Bad Records] Not created and not writen log file when logger is True and
> action as Fail
> ----------------------------------------------------------------------------------------
>
> Key: CARBONDATA-417
> URL: https://issues.apache.org/jira/browse/CARBONDATA-417
> Project: CarbonData
> Issue Type: Bug
> Components: data-load
> Affects Versions: 0.1.1-incubating
> Environment: 3 node Cluster
> Reporter: MAKAMRAGHUVARDHAN
> Priority: Minor
>
> Steps:
> 1. Create Table:
> CREATE TABLE truefail (ID int,CUST_ID int,cust_name string) STORED BY
> 'org.apache.carbondata.format';
> 2. Load Data having Logger as True and Action as False
> LOAD DATA INPATH 'hdfs://hacluster/Raghu/test2.csv' into table truefail
> OPTIONS('DELIMITER'=',' , 'QUOTECHAR'='"','BAD_RECORDS_LOGGER_ENABLE'='TRUE',
> 'BAD_RECORDS_ACTION'='FAIL','FILEHEADER'='ID,CUST_ID,cust_name');
> 0: jdbc:hive2://ha-cluster/default> CREATE TABLE truefail (ID int,CUST_ID
> int,cust_name string) STORED BY 'org.apache.carbondata.format';
> +---------+--+
> | result |
> +---------+--+
> +---------+--+
> No rows selected (0.679 seconds)
> 0: jdbc:hive2://ha-cluster/default> LOAD DATA INPATH
> 'hdfs://hacluster/Raghu/test2.csv' into table truefail
> OPTIONS('DELIMITER'=',' , 'QUOTECHAR'='"','BAD_RECORDS_LOGGER_ENABLE'='TRUE',
> 'BAD_RECORDS_ACTION'='FAIL','FILEHEADER'='ID,CUST_ID,cust_name');
> Error: java.lang.Exception: DataLoad failure: Data load failed due to bad
> record ,The value
> "987654321010111213141516171819101122334455667788990012131415161718191909192939495969798"
> with column name CUST_ID and column data type INT is not a valid Record
> (state=,code=0)
> 0: jdbc:hive2://ha-cluster/default>
> Actual Result: Not Creating and not written log file for bad records when
> BAD_RECORDS_LOGGER_ENABLE'='TRUE', 'BAD_RECORDS_ACTION'='FAIL'
> Expected Result: Should create and write log file when
> BAD_RECORDS_LOGGER_ENABLE'='TRUE', 'BAD_RECORDS_ACTION'='FAIL' for Bad records
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)