1

我使用 SQL Server 2012,我想创建 CLR

我想在 SQL Server 2012 中执行这个命令

CREATE ASSEMBLY AndishCSSCommon FROM 'C:\Andish.CSS.Common.dll'
    WITH PERMISSION_SET=EXTERNAL_ACCESS

但我得到这个错误

Msg 10301, Level 16, State 1, Line 1
Assembly 'Andish.CSS.Common' references assembly 'mscorlib, version=5.0.5.0,  
 culture=neutral, publickeytoken=7cec85d7bea7798e.', which is not present in the current
 database. SQL Server attempted to locate and automatically load the referenced 
assembly     from the same location where referring assembly came from, but that     operation 
has failed     (reason: 2(The system cannot find the file specified.)). Please load the 
referenced     assembly into the current database and retry your request.

并且在我的调试文件夹中不存在 mscorlib.dll

我怎么能CREATE ASSEMBLY从前mscorlib.dllCREATE ASSEMBLY AndishCSSCommon FROM 'C:\Andish.CSS.Common.dll'

4

1 回答 1

0

您可以尝试将目标框架设置为项目中较新的框架

属性 -> 应用程序 -> 目标框架。

于 2013-05-22T10:51:08.600 回答