0
我已經寫了一個CLR storedprocedure,一切都很好,直到今天我已經介紹了一個新的DLL,我試圖註冊一些第三方庫到SqlServer 2008 R2,但是當我運行這個命令:註冊windowsbase程序集SqlServer CLR
CREATE ASSEMBLY [DevExpress.Data] FROM 'C:\MyProject\DevExpress.Data.v12.2.dll' WITH PERMISSION_SET = UNSAFE
的SqlServer拋出我的錯誤:
Assembly 'DevExpress.Data.v12.2' references assembly 'windowsbase, version=3.0.0.0, culture=neutral, publickeytoken=31bf3856ad364e35.', 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(failed to retrieve text for this error. Reason: 15105)). Please load the referenced assembly into the current database and retry your request.
沒有3.0版本出現在C:\ WINDOWS \ Microsoft.Net除了V4.0,所以當我運行
CREATE ASSEMBLY [WindowsBase] FROM 'C:\Windows\Microsoft.NET\Framework\v4.0.30319\WPF\WindowsBase.dll' WITH PERMISSION_SET = UNSAFE
的SqlServer拋出我另一個錯誤:
CREATE ASSEMBLY for assembly 'WindowsBase' failed because the assembly is built for an unsupported version of the Common Language Runtime.
它看起來像有windowsbase的V3.0,但我唯一能找到的關於4.0版。
任何人都可以幫助我!
在此先感謝
馬爾科
Msg 6586,Level 16,State 1,Line 5 無法安裝'WindowsBase'程序集,因爲現有策略會阻止它被使用。 –