使用 dtexec 工具进行安装
参考地址:
http://msdn.microsoft.com/zh-cn/library/ms162810.aspx
例子:
cd C:\Program Files\Microsoft SQL Server\100\DTS\Binn
dtexec /f mypackage.dtsx /set \package.variables[myvariable].Value;myvalue
dtexec /f mypackage.dtsx /config aaa.xml
aaa.xml内容如下 (注意文件编码:最好用utf-8)
<?xml version="1.0"?>
<DTSConfiguration>
<Configuration ConfiguredType="Property" Path="\Package.Variables[User::TestValue].Value" ValueType="String">
<ConfiguredValue>天下无敌</ConfiguredValue>
</Configuration>
</DTSConfiguration>