SSIS文本已截断,状态值为4 [英] SSIS Text was truncated with status value 4

查看:1364
本文介绍了SSIS文本已截断,状态值为4的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发一个SSIS包,试图从CSV平面文件更新现有的SQL表。除了一列之外,所有列都成功更新。如果我在truncate上忽略此列,则我的程序包成功完成。所以我知道这是一个截断问题,而不是错误。

I am developing a SSIS package, trying to update an existing SQL table from a CSV flat file. All of the columns are successfully updating except for one column. If I ignore this column on truncate, my package completes successfully. So I know this is a truncate problem and not error.

这一列几乎每一行都是空的。但是,有几行,其中此字段为200-300个字符。我的数据转换任务将此字段标识为DT_WSTR,但根据我在其他地方阅读的内容,这应该是DT_NTEXT。我试过两个,我甚至将DT_WSTR设置为500.但没有一个解决了我的问题。如何解决?

This column is empty for almost every row. However, there are a few rows where this field is 200-300 characters. My data conversion task identified this field as a DT_WSTR, but from what I've read elsewhere maybe this should be DT_NTEXT. I've tried both and I even set the DT_WSTR to 500. But none of this fixed my problem. How can I fix? What data type should this column be in my SQL table?

Error: 0xC02020A1 at Data Flow Task 1, Source - Berkeley812_csv [1]: Data conversion failed. The data conversion for column "Reason for Delay in Transition" returned status value 4 and status text "Text was truncated or one or more characters had no match in the target code page.".
Error: 0xC020902A at Data Flow Task 1, Source - Berkeley812_csv [1]: The "output column "Reason for Delay in Transition" (110)" failed because truncation occurred, and the truncation row disposition on "output column "Reason for Delay in Transition" (110)" specifies failure on truncation. A truncation error occurred on the specified object of the specified component.
Error: 0xC0202092 at Data Flow Task 1, Source - Berkeley812_csv [1]: An error occurred while processing file "D:\ftproot\LocalUser\RyanDaulton\Documents\Berkeley Demographics\Berkeley812.csv" on data row 758.


推荐答案

我怀疑
或一个或多个字符在目标代码页中没有匹配
部分错误。

I suspect the or one or more characters had no match in the target code page part of the error.

在该列中具有值的行,它加载?
你能识别导致软件包失败的行吗?
它可能是数据太长,或者可能是一些有趣的字符在SQL Server不喜欢。

If you remove the rows with values in that column, does it load? Can you identify, in other words, the rows which cause the package to fail? It could be the data is too long, or it could be that there's some funky character in there SQL Server doesn't like.

这篇关于SSIS文本已截断,状态值为4的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆