December 1, 2010 at 6:24 am
Hello All,
I am getting following problem while using .NET assembly on SQL Server 2008:
Msg 6522, Level 16, State 1, Procedure checkBlock, Line 0
A .NET Framework error occurred during execution of user-defined routine or aggregate "checkBlock":
System.Exception: Data access is not allowed in this context. Either the context is a function or method not marked with DataAccessKind.Read or SystemDataAccessKind.Read, is a callback to obtain data from FillRow method of a Table Valued Function, or is a UDT validation method. Connection=Integrated Security=SSPI;Persist Security Info=True;Initial Catalog=<DBName>;Data Source= (local)
System.Exception:
at Microsoft.VisualBasic.ErrObject.Raise(Int32 Number, Object Source, Object Description, Object HelpFile, Object HelpContext)
at LBSupp.Check.checkBlock(String strCommand)
There is a stored procedure in the database that invokes the user defined function in database named "checkBlock".
This function in turn calls up the function "checkBlock" defined in the .NET DLL "LBSupp".
This same assembly is working on SQL Server 2005 but giving error on SQL Server 2008 while invoking the function defined in it.
Could anyone please assist me to resolve this issue?
Viewing post 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy