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

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

"Data truncation: Data too long for column" causes

I created a MySql table using talend. And with tfileInputDelimited palette, i tried to copy the data present in csv filoe to the table in data base.

While runnung the job, am getting Data truncation: Data too long for column 'First' at row 1 

Please help me in resolving the issue. I am still at learning phase.

Please find the screenshots attached for more details.

Thank u.

Labels (2)
1 Solution

Accepted Solutions
hami1
Creator
Creator

Check the Create Table Component. You might have missed mentioning the column sizes.

Try to run the Job in debug mode

Thanks,

Hameed

View solution in original post

24 Replies
TRF
Champion II
Champion II

Hi,

Is your CSV file aligned on the tFileInputDelimited configuration (fields included between "" and separated by 0683p000009MA9p.png?

Else 1 rows is considered as 1 column and the length may be greater than the DB column definition.

Anonymous
Not applicable
Author

path of the csv file in my pc: "D:/Talend/TOS_DI-20170623_1246-V6.4.1/workspace/Custs.csv"

 

I am not getting what you said. Can you please explain it clearly?


Screenshot (44).png
TRF
Champion II
Champion II

Share a capture of the file content from notepad or notepad++ (not from Excel)

Anonymous
Not applicable
Author

please find the attachment in notepad.

Thank u


Screenshot (45).png
TRF
Champion II
Champion II

Based on your tFileInputDelimited, fields are expected to be enclosed between "" and separated by ;

In your file, there is no "" around fields and separator seems to be a Tab (not a 0683p000009MA9p.png.

When your file is read by your job, it's like there is only 1 field per record.

I suggest you to tick the option "Check each row structure against schema" for tFileInputDelimited Advanced Settings.

Anonymous
Not applicable
Author

Its csv file only. Not a tab separated file. For your understanding, i separated with tab.

Actually there is no error while running the job. But data is not copied from csv file to DataBase.

I also tried with field separator ";". But its not working.

TRF
Champion II
Champion II

The file MUST look like this (once again, based on your tFileInputDelimited configuration):

First;Last;Number;City;State
"vams1";"krishna";"11";"cittoor";"ap"
"amit";"sharea";"22;"bangalore";"ka"
ThWabi
Creator II
Creator II

Hello vamsi1453,

 

could you share the schema definition of your input file component and the database output component?

 

Best regards,

 

Thomas

 

Anonymous
Not applicable
Author

Excel CSV usually take the data as you mentioned.

I think there is no wrong with my CSV as its working fine when i am trying to copy the content of file to another file like tfileinputdelimited to tfileoutputdelimited. Problem arising in case of database only.