使用配置文件配置SSIS项目

时间:2017-09-19 07:29:38

标签: sql-server ssis

您好我正在尝试按照此GitHub项目中的说明提取一些数据。

https://github.com/rohitsies/GNAF-SSIS-Data-Loader

它有8个步骤,我完成了7.最后一个说

“要配置,ssisconfig.dtsConfig在包中可用,只需更改连接字符串,运行包文件,添加配置路径并执行。”

如何将其指向本地sqlserver数据库?

本地服务器数据库名称为ADDRESSES

这是配置文件

 <?xml version="1.0"?>
<DTSConfiguration>
    <DTSConfigurationHeading>
        <DTSConfigurationFileInfo GeneratedBy="DESKTOP-MOLKJJ1\Rohit" GeneratedFromPackageName="BulkLoadData" GeneratedFromPackageID="{D60E622A-F52D-4C6D-9E66-286319027A0B}" GeneratedDate="18/04/2016 11:38:10 PM" />
    </DTSConfigurationHeading>
    <Configuration ConfiguredType="Property" Path="\Package.Connections[add_fk_constraints.sql].Properties[ConnectionString]" ValueType="String">
        <ConfiguredValue>
        F:\Rohit\Work\GitProjects\Resources\FEB16_GNAF_PipeSeparatedValue_20160222170142\G-NAF\Extras\GNAF_TableCreation_Scripts\add_fk_constraints.sql
        </ConfiguredValue>
    </Configuration>
    <Configuration ConfiguredType="Property" Path="\Package.Connections[create_tables_sqlserver.sql].Properties[ConnectionString]" ValueType="String">
        <ConfiguredValue>
                F:\Rohit\Work\GitProjects\Resources\FEB16_GNAF_PipeSeparatedValue_20160222170142\G-NAF\Extras\GNAF_TableCreation_Scripts\create_tables_sqlserver.sql</ConfiguredValue>
    </Configuration>
    <Configuration ConfiguredType="Property" Path="\Package.Connections[Flat File Connection Manager].Properties[ConnectionString]" ValueType="String">
        <ConfiguredValue></ConfiguredValue>
    </Configuration>
    <Configuration ConfiguredType="Property" Path="\Package.Connections[LocalHost.gnaf].Properties[ConnectionString]" ValueType="String">
        <ConfiguredValue>Data Source=.;Initial Catalog=gnaf;Provider=SQLNCLI11.1;Integrated Security=SSPI;Auto Translate=False;</ConfiguredValue>
    </Configuration>
    <Configuration ConfiguredType="Property" Path="\Package.Connections[LocalHost.gnaf 1].Properties[ConnectionString]" ValueType="String">
        <ConfiguredValue>Data Source=.;Initial Catalog=gnaf;Provider=SQLNCLI11.1;Integrated Security=SSPI;Auto Translate=False;</ConfiguredValue>
    </Configuration>
    <Configuration ConfiguredType="Property" Path="\Package\Sequence Container\Foreach Loop Container 1.ForEachEnumerator.Properties[Directory]" ValueType="String">
        <ConfiguredValue>F:\Rohit\Work\GitProjects\Resources\FEB16_GNAF_PipeSeparatedValue_20160222170142\G-NAF\G-NAF FEBRUARY 2016\Standard</ConfiguredValue>
    </Configuration>
    <Configuration ConfiguredType="Property" Path="\Package\Sequence Container 1\Foreach Loop Container.ForEachEnumerator.Properties[Directory]" ValueType="String">
        <ConfiguredValue>F:\Rohit\Work\GitProjects\Resources\FEB16_GNAF_PipeSeparatedValue_20160222170142\G-NAF\G-NAF FEBRUARY 2016\Authority Code</ConfiguredValue>
    </Configuration>
</DTSConfiguration>

我该如何修改?我完全不知道:(

如果这是一个愚蠢的问题,我很抱歉。

1 个答案:

答案 0 :(得分:2)

您可以在以下标记

中进行更改
<ConfiguredValue>
           Data Source=.;
           Initial Catalog=gnaf;
           Provider=SQLNCLI11.1;
           Integrated Security=SSPI;Auto 
           Translate=False;
</ConfiguredValue>

根据您分享的当前指向本地连接的详细信息。