SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2012 Forums
 SSIS and Import/Export (2012)
 error Flat File Destination 1 [220]
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

peace
Constraint Violating Yak Guru

410 Posts

Posted - 10/28/2013 :  04:20:39  Show Profile  Reply with Quote
im getting this error in SSIS to import to CSV file. i tried XLS file same issue. how can i solve this?
already try to increase the output column width but still same error.

error:[Flat File Destination 1 [220]] Error: Data conversion failed. The data conversion for column "column1" returned status value 4 and status text "Text was truncated or one or more characters had no match in the target code page.".

select *
from (
select convert(nvarchar(100),'column1')column1,1 as ordering
union all
select convert(nvarchar(100),column1) column1,2 as ordering from tableA
)x
order by ordering

column1
column1
hgdhgh
asrgag
adfgad
tuhety
dgnnfg
ghsdfg and dghgdh
bsdfbs

Edited by - peace on 10/28/2013 04:24:36

visakh16
Very Important crosS Applying yaK Herder

India
52317 Posts

Posted - 10/28/2013 :  07:04:30  Show Profile  Reply with Quote
check if column1 has enough size to hold full data in ssis metadata

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/
https://www.facebook.com/VmBlogs
Go to Top of Page

peace
Constraint Violating Yak Guru

410 Posts

Posted - 10/28/2013 :  09:10:42  Show Profile  Reply with Quote
column1 in tableA already set as nvarchar 100
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

India
52317 Posts

Posted - 10/28/2013 :  09:17:41  Show Profile  Reply with Quote
Was this casting added later? Check if the metadata set in package is same as current source field length ie DT_WSTR 100 in SSIS

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/
https://www.facebook.com/VmBlogs
Go to Top of Page

peace
Constraint Violating Yak Guru

410 Posts

Posted - 10/28/2013 :  09:30:53  Show Profile  Reply with Quote
the table already set earlier with nvarchar 100

already checked in ssis length..applied 100
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.08 seconds. Powered By: Snitz Forums 2000