错误SSIS Excel源 - 连接管理器类型不正确 [英] Error SSIS Excel Source - connection manager incorrect type
本文介绍了错误SSIS Excel源 - 连接管理器类型不正确的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试使用SSIS通过代码从Excel导入到SQL Server并使用以下连接信息。
Hi,
I am trying to import from Excel to SQL Server using SSIS through code and used the following connection information.
connectionManager = package.InnerObject.Connections.Add(ExcelMoniker);
connectionManager.Properties["ConnectionString"].SetValue(connectionManager, string.Format(@"Provider=Microsoft.ACE.OLEDB.12.0;Data Source={0};Extended Properties=""Excel 12.0;HDR=YES""", excelDataSource.FileName));
当 AcquireConnections
方法调用它时抛出异常
HRESULT异常:0xC020801E
连接管理器__类型不正确。所需类型为__。组件可用的类型是__。
请帮忙。
问候,
hari。
At the time of AcquireConnections
method calling it is throwing an exception
"Exception from HRESULT: 0xC020801E"
The connection manager "__" is an incorrect type. The type required is "__". The type available to the component is "__".
Please help.
Regards,
hari.
推荐答案
我的猜测是你没有安装office 2007数据连接组件...
http://www.microsoft.com/downloads/details.aspx?familyid=7554f536-8c28-4598-9b72-ef94e038c891&displaylang=en [ ^ ]
祝你好运!
My guess is that you didn't install the office 2007 data connectivity components...
http://www.microsoft.com/downloads/details.aspx?familyid=7554f536-8c28-4598-9b72-ef94e038c891&displaylang=en[^]
Good luck!
这篇关于错误SSIS Excel源 - 连接管理器类型不正确的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文