无法加载文件或程序集microsoft.sqlserver.sqlclrprovider 13.100.0.0 [英] Could not load file or assembly microsoft.sqlserver.sqlclrprovider 13.100.0.0

查看:532
本文介绍了无法加载文件或程序集microsoft.sqlserver.sqlclrprovider 13.100.0.0的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用SQLServer程序集运行
Microsoft.SqlServer.ConnectionInfo(13.100.0.0)
Microsoft.SqlServer.SMO(13.100.0.0)

I run my Winforms app using SQLServer assemblies Microsoft.SqlServer.ConnectionInfo (13.100.0.0) Microsoft.SqlServer.SMO(13.100.0.0)

在同一台计算机上安装了SSMS 2016(八月)。
并且这里也安装了SQL 2014 Dev Edition。

On the same machine SSMS 2016(Aug) is installed. And here SQL 2014 Dev Edition is installed too.

当我运行我的应用程序时,它给了我一个错误:

WHen I run my app it gives me an error:

сonnection = new ServerConnection(instanceName);
------------
Could not load file or assembly ‘microsoft.sqlserver.sqlclrprovider version=13.100.0.0′

我已经检查过:GAC包含一些这样的程序集11,12,13.0.0.0,但是没有13.100.0.0。

I have checked: GAC contains some this assemblies 11, 12, 13.0.0.0, but there is no 13.100.0.0.

应用程序从以下位置获得了引用的程序集:
C:\Program Files(x86)\Microsoft SQL Server\130\DTS\Tasks

The application has got referenced assemblies from: C:\Program Files (x86)\Microsoft SQL Server\130\DTS\Tasks

Microsoft.SqlServer.ConnectionInfo (13.100.0.0)
Microsoft.SqlServer.SMO(13.100.0.0)

我的操作系统是Windows 7,我认为所有13.100.0.0都是由SSMS安装程序安装的。
如何解决这个问题?我在哪里可以找到程序集
microsoft.sqlserver.sqlclrprovider 13.100.0.0?

My OS is Windows 7 and I think all 13.100.0.0 were installed by SSMS installer. How to solve this problem? WHere I can find the assembly microsoft.sqlserver.sqlclrprovider 13.100.0.0?

推荐答案

我遇到了同样的问题。通过更新的SSMS,主SMO现在安装在 C:\Program Files(x86)\Microsoft SQL Server\130\DTS\Tasks VS中的13.100.0.0版本(Microsoft.SqlServer.Smo.dll文件具有13.0.15700.28版本),但GAC中没有引用Microsoft.SqlServer.SqlClrProvider.dll。当我使用SSMS附带的代码时,我的代码中进一步出现了异常。

I had the same issue. With the updated SSMS, the main SMO are now installed in "C:\Program Files (x86)\Microsoft SQL Server\130\DTS\Tasks" with the version 13.100.0.0 in VS (the Microsoft.SqlServer.Smo.dll file has the 13.0.15700.28 version) but there is no Microsoft.SqlServer.SqlClrProvider.dll referenced in GAC. When I take the one provided with SSMS, I get an exception further into my code.

问题是SSMS的安装程序将这些私有SMO的引用添加到列表中。 Visual Studio的参考。 Charles Gagnon给了我一个在我的 .csproj 文件中实现的变通办法(使用HintPath)。

The problem is that the installer of SSMS adds reference of these private SMO to list of references of Visual Studio. Charles Gagnon gave me a workaround (the use of the HintPath) that I implemented in my .csproj files.

这篇关于无法加载文件或程序集microsoft.sqlserver.sqlclrprovider 13.100.0.0的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆