When
we will deploy a CLR objects like CLR stored procedures, CLR data types etc
from visual studio we may get error message like:
Deploy error SQL01268: .Net SqlClient Data Provider: Msg 6212,
Level 16, State 1, Line 1 CREATE ASSEMBLY failed because method '' on type ''
in safe assembly '' is storing to a static field. Storing to a static field is
not allowed in safe assemblies.
Solution:
Set
the permission level of your project unsafe. For this select Database tab in properties window of
your project and choose Permission level Unsafe.
Now build the project
solution.
No comments:
Post a Comment