Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/sql-server/26.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/powershell/13.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Sql server 应该从哪里加载Microsoft.SqlServer.Management.IntegrationServices.dll?_Sql Server_Powershell_Ssis - Fatal编程技术网

Sql server 应该从哪里加载Microsoft.SqlServer.Management.IntegrationServices.dll?

Sql server 应该从哪里加载Microsoft.SqlServer.Management.IntegrationServices.dll?,sql-server,powershell,ssis,Sql Server,Powershell,Ssis,我需要使用SQL Server库,如Microsoft.SqlServer.Management.IntegrationServices.dll。识别要加载的正确.dll的最佳实践是什么?是否存在应使用的环境变量或PowerShell变量 在我的系统中,这个文件有很多版本。如何选择一个女孩 PS C:\> dir -Recurse -Filter 'Microsoft.SqlServer.Management.IntegrationServices.dll' -ErrorAction Si

我需要使用SQL Server库,如Microsoft.SqlServer.Management.IntegrationServices.dll。识别要加载的正确.dll的最佳实践是什么?是否存在应使用的环境变量或PowerShell变量

在我的系统中,这个文件有很多版本。如何选择一个女孩

PS C:\> dir -Recurse -Filter 'Microsoft.SqlServer.Management.IntegrationServices.dll' -ErrorAction SilentlyContinue | select CreationTime,Length,FullName

CreationTime        Length FullName
------------        ------ --------
2020-07-07 15:40:44 254736 C:\Program Files\WindowsPowerShell\Modules\SqlServer\21.1.18226\Microsoft.SqlServer.Management
2020-03-18 01:31:22 250976 C:\Program Files (x86)\Microsoft SQL Server Management Studio 18\Common7\IDE\CommonExtensions\
2020-04-16 16:39:24 254024 C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\CommonExtensions\
2019-12-26 11:17:24 245856 C:\src\dbatools\bin\smo\Microsoft.SqlServer.Management.IntegrationServices.dll
2020-06-24 09:04:24 250984 C:\Users\lit\Documents\WindowsPowerShell\Modules\dbatools\1.0.113\bin\smo\Microsoft.SqlSe
2020-02-11 12:40:24 254736 C:\Users\lit\Documents\WindowsPowerShell\Modules\SqlServer\21.1.18218\Microsoft.SqlServer
2019-12-23 11:31:14 184000 C:\Windows\assembly\GAC_MSIL\Microsoft.SqlServer.Management.IntegrationServices\11.0.0.0__8984
2019-12-23 11:32:04 174784 C:\Windows\assembly\GAC_MSIL\Microsoft.SqlServer.Management.IntegrationServices\12.0.0.0__8984
2019-12-23 11:32:57 210624 C:\Windows\assembly\GAC_MSIL\Microsoft.SqlServer.Management.IntegrationServices\13.0.0.0__8984
2019-12-31 09:48:15 252584 C:\Windows\assembly\GAC_MSIL\Microsoft.SqlServer.Management.IntegrationServices\14.0.0.0__8984
其他信息:

目标是读取一些SSIS包,应用日志记录设置,并将它们保存回磁盘。我的研究引导我使用SQL Server库。但是,如何选择要加载的正确库还不清楚

我的系统上有十(10)个“Microsoft.SqlServer.Management.IntegrationServices.dll”文件。是否每个工具和应用程序都认为应该将其复制到自己的目录中

查看.dtsx文件将指定应使用哪个SQL Server库版本。这些包当前正在SQL Server 2016上运行。这些指标是什么

DTS:LastModifiedProductVersion="14.0.3002.113"
<Reference Include="Microsoft.SqlServer.ManagedDTS, Version=13.0.0.0, Cult...
DTS:LastModifiedProductVersion=“14.0.3002.113”

Mark&Ferdipux说得对-你可能想要GAC中的内容

SSIS程序集是特定于版本的

  • 15:=SQL Server 2019
  • 14:=SQL Server 2017
  • 13:=SQL Server 2016
  • 12:=SQL Server 2014
  • 11:=SQL Server 2012
  • 10.5:=SQL Server 2008R2
  • 10:=SQL Server 2008
  • 9:=SQL Server 2005
您需要将应用程序程序集与将要部署应用程序的SQL Server版本对齐


正如您所确定的,您将要创建针对SQL Server 2016的SSIS包,那么您将需要程序集
C:\Windows\assembly\GAC_MSIL\Microsoft.SqlServer.Management.IntegrationServices\13.0.0.0_u8984

从GAC中选择适当的版本,即14.0.0.0…@MarkWojciechowicz,谢谢。考虑到我的系统上有四(4)个GAC_MISL目录(11、12、13和14),我如何可靠地选择正确的目录?它不能是最近的CreationTime或LastWriteTime。最大数字(14)是否总是正确的?加载DLL的任务是什么?您试图实现什么?这将取决于您希望使用的SSI版本。14是SQL 2017,13是SQL 2016,12是SQL 2014。我猜你会想要最新的。。您还希望这与代码部署到的位置保持一致。这是有用的信息,但我仍然需要知道应该使用哪个版本。我已在问题中添加了有关预期目标的信息。我认为我的研究给我带来了一个简洁的问题,但显然不是。抱歉。您需要与sql server 2016关联的程序集。是的,从您提供的表中可以清楚地看到这一点。代码将如何选择正确的库。这是否需要作为参数或配置要求?.ddl文件是否保证位于C:?我不希望硬编码.ddl文件的路径。这在Linux上如何工作?@lit,我通常会在VS中创建一个具有所有逻辑的通用项目,并使用项目自定义属性(如
SQL2016
)创建项目。一般项目指的是所有顶级DLL,侧面项目指的是对应SSIS版本的DLL。然后编译并运行适当的项目。SSIS在Linux上不工作,因此您可能不必担心。@Ferdipux,这是否意味着
C:\Windows\assembly\GAC\u MSIL\Micr…
路径是基于自定义属性硬编码的?它是否可以安装为使GAC_MSIL目录位于不同的卷上:
D:
F: