I currently am writing my own CLR Stored Procedure and I need to use a solver from Microsoft Solver Foundation.
In order to be able to add the reference to Microsft Solver Foundation in my CLR Project, I need to add that assembly to my SQL Server instance (source). So I installed MS Solver Foundation Redistributable and registered it in SQL Server using the following script as server admin:
USE MYDB
ALTER DATABASE MYDB SET TRUSTWORTHY ON WITH ROLLBACK IMMEDIATE
ALTER DATABASE MYDB SET TRUSTWORTHY ON
CREATE ASSEMBLY MicrosoftSolverFoundation
AUTHORIZATION dbo
FROM 'C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\Microsoft.Solver.Foundation.dll'
WITH PERMISSION_SET = UNSAFE
However, I get the following error:
Assembly 'MicrosoftSolverFoundation' could not be installed because existing policy would keep it from being used.
Additional Information
CLR Version:
directory C:\Windows\Microsoft.NET\Framework64\v4.0.30319\
version v4.0.30319
state CLR is initialized
SQL Server Version:
Microsoft SQL Server 2012 (SP1) - 11.0.3128.0 (X64)
Dec 28 2012 20:23:12
Copyright (c) Microsoft Corporation
Enterprise Edition: Core-based Licensing (64-bit) on Windows NT 6.1 <X64> (Build 7601: Service Pack 1) (Hypervisor)