【问题标题】:Is it necessary to have MS excel software installed on the target machine while exporting data from SSIS to excel将数据从SSIS导出到excel时是否需要在目标机器上安装MS excel软件
【发布时间】:2017-06-24 07:47:57
【问题描述】:

在我的开发机器中,我安装了 MS excel。我能够通过 SSIS(Visual Studio)将数据从 DB 导出到 excel 中。但是当我将它部署到未安装 MS excel 的 QA 环境中时,该软件包失败并出现以下错误。如果在通过 SSIS 将数据库中的数据导出到 excel 时确实需要在目标机器上安装 MS excel 软件,请帮助我。

这是我正在使用的查询在 excel 表中创建 excel 和选项卡。 创建 excel 文件并在其中“插入”新选项卡。

CREATE TABLE Inserted(

 [fileid] integer 
      ,[filename] string
      ,[rxcui] string 
      ,[tty] string
      ,[rxnorm_description] string
      ,[related_brand_name] string
      ,[related_scdc] string
      ,[related_df] string
      ,[related_ndc] string
      ,[create_date] date
      ,[create_user] string 
      ,[status] string
      ,[plan_year] string
      ,[update_date] date
      ,[update_user]string 
)

用于上述脚本的连接管理器:

@[User::var_excel_destination] +"\\"+"FRF_File_Import_Detail_"+ Right("0" +(DT_STR,4,1252) datepart("yyyy", getdate()),4)  
+ Right("0" +(DT_STR,2,1252) datepart("mm", getdate()) ,2)
+ Right("0" +(DT_STR,2,1252) datepart("dd", getdate()),2)+Right("0" + (DT_STR,2,1252) DatePart("hh",getdate()),2) 
+ Right("0" + (DT_STR,2,1252) DatePart("mi",getdate()),2) 
+ Right("0" + (DT_STR,4,1252) DatePart("ss",getdate()),2) +".xls"

在这一步失败并出现以下错误:

错误描述:无法获取连接“ECM FRF 文件导入处理器”。连接可能未正确配置,或者您可能没有此连接的正确权限。

请帮忙。

【问题讨论】:

  • 我为您的问题提供了正确答案。

标签: sql-server excel ssis etl


【解决方案1】:

不,唯一需要的是喷气发动机。 https://www.microsoft.com/en-us/download/details.aspx?id=13255

【讨论】:

    【解决方案2】:

    是的,它需要在系统中安装MSexcel。因为没有它我们没有内部定义来让系统完全了解文件格式。

    【讨论】:

    • 您好 Chetan,感谢您的意见,但在这里的其中一篇文章中说不是真的需要。请参考以下链接以供参考。 stackoverflow.com/questions/19710758/…
    • 我的错,那里的答案说,如果你没有 32 位系统,你可能需要(我有 64 位系统,当我做同样的任务时,我发现,excel 是安装在目标机器上很重要)
    • 嗨 Chetan,请参阅此链接了解更多详情。 social.msdn.microsoft.com/Forums/en-US/…
    • 而且,通过 SSIS 将数据导出到 excel 时,Excel 软件不是强制性的。我已经在 Visual Studio 上执行了它。它正在创建文件。但是,问题是当我通过 SQL 作业运行部署的 SSIS 包时。
    • 好的,我的错。谢谢
    【解决方案3】:

    我刚刚在 SQL Server 作业上设置了以 32 位模式运行。它就像一个魅力。

    【讨论】:

    • 好消息杰森。非常感谢你。但我的场景中的问题是: 1. 我安装了 32 位的 Microsoft.Jet.OLEDB.4.0。 2. 将 SSDT 设置为 32 位模式运行。 3. 它在 SSDT 中运行良好。 4. 部署并要求运行 SQL 作业时,它失败了。 5. 我将作业的属性设置为“运行时 32 位”,并且工作起来很迷人。
    猜你喜欢
    • 2013-11-11
    • 1970-01-01
    • 1970-01-01
    • 2011-10-22
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多