本文介绍了我在SQL中创建程序集,但它给出了错误。那么如何解决呢。给出一些想法。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
从'C:\ Users \ ....... \Projects\CLRDemo \CLRDemo \bin \Debug \CLRDemo.dll'FRE CREATE ASSEMBLY CLRDemo PERMISSION_SET =安全;
我使用此代码在sql中创建程序集。
但是它给出了这个错误。
程序集'CLRDemo'引用程序集'system.runtime.serialization,version = 4.0.0.0,culture = neutral,publickeytoken = b77a5c561934e089 。',这在当前数据库中不存在。 SQL Server尝试从引用程序集来自的相同位置定位并自动加载引用的程序集,但该操作失败(原因:2(系统找不到指定的文件。))。请将引用的程序集加载到当前数据库中并重试您的请求。
我尝试过:
没试过,因为在我创建之前我已经放弃了那个程序集。之后我想创建但它给我错误。
解决方案
CREATE ASSEMBLY CLRDemo FROM 'C:\Users\.......\Projects\CLRDemo\CLRDemo\bin\Debug\CLRDemo.dll' WITH PERMISSION_SET = SAFE;
I use this code to create assembly in sql.
But it is giving this error.
Assembly 'CLRDemo' references assembly 'system.runtime.serialization, version=4.0.0.0, culture=neutral, publickeytoken=b77a5c561934e089.', 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.
What I have tried:
Not tried , because before it i have create but i drop that assembly. After that i want to create but it is giving error to me.
解决方案
这篇关于我在SQL中创建程序集,但它给出了错误。那么如何解决呢。给出一些想法。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!