Search code examples
.netsql-serverentity-frameworksqlclrclrstoredprocedure

After updating Entity Framework my CLR StoredProcedure stopped working until I compiled it again


I ask this question before sql server clr-how to call wcf service in clr sql stored procedure in visual studio and create a stored procedure to call wcf service but when I update entity framework 4.5 to 4.5.1 on my server stored procedure not work and its error around of System.ServiceModel assembly
I forced to do all step in answer of my old question and publish stored procedure again to work.

but I confused, because my sql server is 2008 r2 and it work with entity framework 3.5, why I must republish my stored procedure and all steps Can any one help me?


Solution

  • I think your way to solve problem is not correct,
    For Call WCF Service in SQL Server you must use System.Web.Service instead of System.ServiceModule
    I you use this assembly you do not force to add

    • System.Messaging
    • System.IdentityModel
    • System.IdentityModel.Selectors
    • Microsoft.Transactions.Bridge
    • System.Runtime.Serialization
    • System.ServiceModel

    this way is very simple, just add service like old web service
    for more information use Calling WCF in CLR