Noob SSIS question please. I am working on a simple database conversion script. The original data source have the phone number saved as a string with len = 50 in a column called Phone1. The destination table has the telephone number saved as a string with len = 20 in a column called Telephone. I keep getting this warning:
[110]] Warning: Truncation may occur due to inserting data from data flow column "Phone1" with a length of 50 to database column "Telephone" with a length of 20.
I have tried a few things including adding a Derived Column task to Cast the Phone1 into a DT_WSTR string with length = 20 - (DT_WSTR, 20) (SubString(Phone1, 1, 20)) and adding a DataConversion tasks to convert the field Phone1 from WT_WSTR(50) into WT_WSTR(20) but none of them work. I know I can SubStr phone1 in the SQL String @ the OLEDB Source but I would love to find out how SSIS deals with this scenario
Root cause - This warning message appears over the SSIS data flow task when the datatype length of the source column is more than the datatype length of the destination column.
Resolution - In order to remove this warning message from SSIS solution, make sure datatype length of the source column should be equal to the datatype length of the destination column.
Warning: Truncation may occur due to inserting data from data flow column "Phone1" with a length of 50 to database column "Telephone" with a length of 20.
Solution :
To remove the warning mentioned above, you may follow the below steps:
1)Right click on source components (for ex: flat file) and click on show advance editor.
2)Go to input and output properties.
3)Click on flat file source Output -->Output column --> select (PhoneNo)
4)You may get the properties window for phoneno click on Length property and change the value to 20. Click to Ok.
I wish this may help you.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With