[英]Unable to cast object of type 'System.Collections.Generic.List`1[System.Decimal]' to type 'System.IConvertible'
[英]SSIS: Unable to cast object of type 'System.Decimal' to type 'System.Char[]'
我正在做從SQL Server 2008 R2到PostgreSQL 9.5的數據集成。
我有以下詳細信息的表:
表 :在SQL Server中
create table test
(
cola int,
colb numeric(18,0),
colc varchar(50),
cold datetime,
cole bit,
colf char(1)
);
表 :在PostgreSQL中
create table test
(
cola int,
colb numeric(18,0),
colc varchar(50),
cold timestamp(0),
cole boolean,
colf char(1)
);
套餐詳情:
源:OLE DB源(SQL Server)
數據轉換:在列colc
到DT_WSTR
目標:ADO NET目標(PostgreSQL)
錯誤詳情:
[ADO NET目標[129]]錯誤:在數據插入期間發生異常,提供程序返回的消息為:無法將類型為“ System.Decimal”的對象轉換為類型為“ System.Char []”。
樣本數據:在SQL Server中
insert into test1 values(1,NULL,'z','2017-02-12 12:21:50.000',1,'C');
insert into test1 values(2,1344,'Xuz','2017-02-12 12:21:50.000',0,'D');
insert into test1 values(3,NULL,'T','2017-02-12 12:21:50.000',1,'E');
輸入和輸出屬性 :
您的列映射看起來不錯,您必須使用高級編輯器檢查列數據類型。
右鍵單擊Ado.net Destination
-> Input and Output Columns
選項卡->檢查列數據類型是否正確定義。
colb
:為什么轉換colb
如果它是數字列)
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.