Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Write Table now available in Qlik Cloud Analytics: Read Blog
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

problem in import Excel to MySQL

Hi friends,

 

i'm new in talend and i want to know if there a solution to get error. Ex: when i run the job 1000 lines is in databse, but when i have error in line 1001 and i correct the error i want ton continu the job, one solution i have is truncat database and reflate the job and start in ligne 1 not 1001, i want to continu job in line 1001

 

thanks you

Labels (2)
1 Solution

Accepted Solutions
TRF
Champion II
Champion II

Hi,

You may include a status field in the Excel file and put a value (OK or KO) in this field field depending on the operation result.

Then when you read the Excel file, you just have to filter the input rows to exclude whose with status = OK.

You may also start with the your previous post (https://community.talend.com/t5/Design-and-Development/Insert-new-record-if-not-exist-in-database/m-...); add a primary key on the target table and ignore duplicate keys on insert (not too clean).

Finally, you may set the header field for the tFileInputExcel to 1001 other to ignore top records.

The number of records to be ignored can be defined using a context variable.

Just activate prompt on variable for the corresponding variable and you you will be prompted to enter a value for the variable when the job starts. 

 

Hope this helps.

View solution in original post

3 Replies
TRF
Champion II
Champion II

Hi,

You may include a status field in the Excel file and put a value (OK or KO) in this field field depending on the operation result.

Then when you read the Excel file, you just have to filter the input rows to exclude whose with status = OK.

You may also start with the your previous post (https://community.talend.com/t5/Design-and-Development/Insert-new-record-if-not-exist-in-database/m-...); add a primary key on the target table and ignore duplicate keys on insert (not too clean).

Finally, you may set the header field for the tFileInputExcel to 1001 other to ignore top records.

The number of records to be ignored can be defined using a context variable.

Just activate prompt on variable for the corresponding variable and you you will be prompted to enter a value for the variable when the job starts. 

 

Hope this helps.

Anonymous
Not applicable
Author

Thanks you so much

Anonymous
Not applicable
Author

I would like to have an error file/table where I would like to see something like below
rec_key|record|error_code|error_msg
Ex:
1|a;shong|NUMERIC_CHECK_FAILED|id has a bad value "a"
6|f;Lee|NUMERIC_CHECK_FAILED|id has a bad value "f"
22|h;nike|NUMERIC_CHECK_FAILED|id has a bad value "h"

how can i do it?