I have a bunch of SQL CLR assemblies on SQL 2008 R2. These assemblies were targeted with .Net Framework 3.5. Given SQL 2008 supported 2.0 .NET framework version, I am assumi
I was able to get to the root cause of the issue I was facing. SQL 2012 supports .NET framework version 4.0 for SQLCLR and hence loads all framework assemblies from 4.0 framework. Hence I needed to upgrade all my assemblies to use 4.0 framework assemblies. http://blogs.msdn.com/b/dohollan/archive/2012/04/20/sql-server-2012-sqlclr-net-framework-version.aspx?CommentPosted=true#commentmessage
But things didnt work for me even after that. It turns out in 4.0, .NET changed some framework assemblies like System.ServiceModel from Pure .Net assemblies to mixed mode assemblies. Such assemblies cannot be loaded by SQL CLR. So all user defined assemblies depending on mixed mode assemblies pre 2012 dont work anymore on 2012 :( Most badly hit are previously working SQL and WCF integrations completely breaking in 2012 sicne WCF depends on ServiceModel. More here http://blogs.msdn.com/b/psssql/archive/2013/02/23/unable-to-register-net-framework-assembly-not-in-the-supported-list.aspx
We ended up writing a simple Webservice wrapper over our WCF operation and writing a Webservice client in SQLCLR.