none
Microsoft.SqlServer.SqlClrProvider...dll ver 10.xx

    Question

  • I am developing on a machine (XP Prof SP2  32bit) with sql server 2008, VS 2008 and .NEt v3.0 SP1

    I have no problems on my machine but when testing on other machines I get error:

    And I did include Microsoft.SqlServer.Smo.dll, Microsoft.SqlServer.Management.Sdk.Sfc.dll,  Microsoft.SqlServer.ConnectionInfo.dll and Microsoft.SqlServer.Management.Collector.dll so, I am really confused and I can't seem to find
    file or assembly 'Microsoft.SqlServer.SqlClrProvider, Version=10.0.0.0.
                          Any help would be much apreciated.




    ************** Exception Text **************
    Microsoft.SqlServer.Management.Smo.FailedOperationException ---> Microsoft.SqlServer.Management.Sdk.Sfc.EnumeratorException: Failed to retrieve data for this request. ---> System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.SqlServer.SqlClrProvider, Version=10.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91' or one of its dependencies. The system cannot find the file specified.
    File name: 'Microsoft.SqlServer.SqlClrProvider, Version=10.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91'
       at Microsoft.SqlServer.Management.Sdk.Sfc.ObjectLoadInfoManager.LoadHierarchy()
       at Microsoft.SqlServer.Management.Sdk.Sfc.ObjectLoadInfoManager.GetFirstObjectLoadInfo(Urn urn)
       at Microsoft.SqlServer.Management.Sdk.Sfc.Environment.GetServerVersion(Urn urn, Object ci)
       at Microsoft.SqlServer.Management.Sdk.Sfc.Environment.GetObjectInfo(Object ci, RequestObjectInfo req)
       at Microsoft.SqlServer.Management.Sdk.Sfc.Enumerator.GetObjectInfo(Object connectionInfo, RequestObjectInfo requestObjectInfo)
       at Microsoft.SqlServer.Management.Sdk.Sfc.Enumerator.FixPropertyList(Object connectionInfo, Urn urn, String[] fields, RequestFieldsTypes requestFieldsType)
       at Microsoft.SqlServer.Management.Sdk.Sfc.Enumerator.GetData(Object connectionInfo, Request request)
       at Microsoft.SqlServer.Management.Sdk.Sfc.Enumerator.Process(Object connectionInfo, Request request)

    WRN: Assembly binding logging is turned OFF.
    To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
    Note: There is some performance penalty associated with assembly bind failure logging.
    To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

       --- End of inner exception stack trace ---
       at Microsoft.SqlServer.Management.Sdk.Sfc.Enumerator.Process(Object connectionInfo, Request request)
       at Microsoft.SqlServer.Management.Sdk.Sfc.Enumerator.GetData(Object connectionInfo, Urn urn)
       at Microsoft.SqlServer.Management.Smo.SmoApplication.EnumAvailableSqlServers(Boolean localOnly)
       --- End of inner exception stack trace ---
       at Microsoft.SqlServer.Management.Smo.SmoApplication.EnumAvailableSqlServers(Boolean localOnly)
       at ABSystemInfo.Form1.button1_Click(Object sender, EventArgs e)
       at System.Windows.Forms.Control.OnClick(EventArgs e)
       at System.Windows.Forms.Button.OnClick(EventArgs e)
       at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
       at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
       at System.Windows.Forms.Control.WndProc(Message& m)
       at System.Windows.Forms.ButtonBase.WndProc(Message& m)
       at System.Windows.Forms.Button.WndProc(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


    ************** Loaded Assemblies **************
    mscorlib
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.42 (RTM.050727-4200)
        CodeBase: file:///C:/WINDOWS/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
    ----------------------------------------
    AB_System_info
        Assembly Version: 1.0.0.0
        Win32 Version: 1.0.0.0
        CodeBase: file:///C:/Ab%20system%20info/AB_System_info.exe
    ----------------------------------------
    System.Windows.Forms
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.42 (RTM.050727-4200)
        CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
    ----------------------------------------
    System
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.42 (RTM.050727-4200)
        CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
    ----------------------------------------
    System.Drawing
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.42 (RTM.050727-4200)
        CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
    ----------------------------------------
    System.Management
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.42 (RTM.050727-4200)
        CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Management/2.0.0.0__b03f5f7f11d50a3a/System.Management.dll
    ----------------------------------------
    System.Data
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.42 (RTM.050727-4200)
        CodeBase: file:///C:/WINDOWS/assembly/GAC_32/System.Data/2.0.0.0__b77a5c561934e089/System.Data.dll
    ----------------------------------------
    Microsoft.SqlServer.Smo
        Assembly Version: 10.0.0.0
        Win32 Version: 10.0.1442.32 ((SQL_PreRelease).080529-2343 )
        CodeBase: file:///C:/Ab%20system%20info/Microsoft.SqlServer.Smo.DLL
    ----------------------------------------
    System.Xml
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.42 (RTM.050727-4200)
        CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll
    ----------------------------------------
    System.Transactions
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.42 (RTM.050727-4200)
        CodeBase: file:///C:/WINDOWS/assembly/GAC_32/System.Transactions/2.0.0.0__b77a5c561934e089/System.Transactions.dll
    ----------------------------------------
    System.EnterpriseServices
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.42 (RTM.050727-4200)
        CodeBase: file:///C:/WINDOWS/assembly/GAC_32/System.EnterpriseServices/2.0.0.0__b03f5f7f11d50a3a/System.EnterpriseServices.dll
    ----------------------------------------
    System.Configuration
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.42 (RTM.050727-4200)
        CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Configuration/2.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
    ----------------------------------------
    Microsoft.SqlServer.Management.Sdk.Sfc
        Assembly Version: 10.0.0.0
        Win32 Version: 10.0.1442.32 ((SQL_PreRelease).080529-2343 )
        CodeBase: file:///C:/Ab%20system%20info/Microsoft.SqlServer.Management.Sdk.Sfc.DLL
    ----------------------------------------
    Microsoft.SqlServer.ConnectionInfo
        Assembly Version: 10.0.0.0
        Win32 Version: 10.0.1442.32 ((SQL_PreRelease).080529-2343 )
        CodeBase: file:///C:/Ab%20system%20info/Microsoft.SqlServer.ConnectionInfo.DLL
    ----------------------------------------


    • Moved by Bob BeaucheminMVP Wednesday, September 05, 2012 3:27 PM Moved to a more appropriate forum for best response (From:.NET Framework inside SQL Server)
    Thursday, August 14, 2008 7:46 AM

Answers

  • The fix is to install the SQL 2008 SMO package on the destination machines.  You can find the installer on the following link:

     

    http://www.microsoft.com/downloads/details.aspx?FamilyId=C6C3E9EF-BA29-4A43-8D69-A2BED18FE73C&displaylang=en

     

    Before you can install SMO 10, you will need to install the 2008 CLR Types package onto the machine as SMO is dependant on the CLR Types which can also be found on the link above.

     

    EDIT:

     

    The other thing to do, is to Add A Setup Wizard to the Solution as a new project:

    1. Right Click on the Solution in the Solution Explorer
    2. Click Add
    3. Select New Project.
    4. Expand Other Project Types and Click Setup and Deployment
    5. Double Click Setup Wizard
    6. Provide a Name for the Project and click ok
    7. Click Next
    8. Click Create a Setup for a Windows Application
    9. Click Next
    10. Check Primary Output from <ProjectName>
    11. Click Next
    12. Click Next
    13. Click Finished.

    This will add the needed Dependencies into the Setup Project, including the needed SMO 10 Assemblies from the GAC.  These will then be copied to the Application Install folder when setup runs, allowing the app to run.

    Tuesday, October 07, 2008 8:09 PM
    Moderator

All replies

  • Hey

    Did you find answer to your question?

    I have simillar problem with Visual Studio 2008 SP1, SQL Server 2005.
    The problem seems to emerge while loading Microsoft.SqlServer.Management.Common or  Microsoft.SqlServer.Management.Smo assembly.
    Tuesday, August 26, 2008 4:37 PM
  • We are upgrading from VS2008 to VS2008 SP1.

     

    I have 1 box with Windows Server08 + VS2008 SP1+ SQLServer 2005

    Another box with Windows Server03 + VS2008 + SQLServer 2005

     

    Many (if not all) of our csproj files that use sql api are failing to build due to a missing reference to Microsoft.SqlServer.Mangement.sdk.sfc. This assembly is present on the Sp1 PC but not the nonSP1 box.

     

    I am not sure if this is a VS2008 SP1 issue or Server2008. I think it's SP1 because the same code build on Vista Ultimate with Vs2008.

     

     

    Wednesday, August 27, 2008 3:51 PM
  • Visual Studio 2008 SP1 comes with Microsoft.SqlServer.Smo.dll version 10.0 whereas Visual Studio 2008 has version 9.0

    Only SMO 10.0 version has dependency on Sdk.sfc dll. My guess is on your SP1 box, it is trying to load 10.0 SMO and hence cribbing for missing reference to sdk.sfc dll. If you make your program to use only 9.0 version of SMO and other dlls that you have add reference for then you should not see this issue. BTW, SQL Server 2005 would have 9.0 version of these dlls.

     

    Thanks,

    Sravanthi

    Wednesday, September 10, 2008 8:57 AM
    Moderator
  • The fix is to install the SQL 2008 SMO package on the destination machines.  You can find the installer on the following link:

     

    http://www.microsoft.com/downloads/details.aspx?FamilyId=C6C3E9EF-BA29-4A43-8D69-A2BED18FE73C&displaylang=en

     

    Before you can install SMO 10, you will need to install the 2008 CLR Types package onto the machine as SMO is dependant on the CLR Types which can also be found on the link above.

     

    EDIT:

     

    The other thing to do, is to Add A Setup Wizard to the Solution as a new project:

    1. Right Click on the Solution in the Solution Explorer
    2. Click Add
    3. Select New Project.
    4. Expand Other Project Types and Click Setup and Deployment
    5. Double Click Setup Wizard
    6. Provide a Name for the Project and click ok
    7. Click Next
    8. Click Create a Setup for a Windows Application
    9. Click Next
    10. Check Primary Output from <ProjectName>
    11. Click Next
    12. Click Next
    13. Click Finished.

    This will add the needed Dependencies into the Setup Project, including the needed SMO 10 Assemblies from the GAC.  These will then be copied to the Application Install folder when setup runs, allowing the app to run.

    Tuesday, October 07, 2008 8:09 PM
    Moderator
  • Reinstall VS2008 SP1
    Tuesday, December 02, 2008 11:34 AM
  • I had the same problem and finally figured it out.  Microsoft.SqlServer.SqlClrProvider is shipped as part of the SQL 2008 SMO objects (which requires SQL 2008 CLR Types).  It only installs the dll into the GAC and not into the SDK folder where many of the other Mcirosft.SqlServer.* assemblies live (yay consistency!).

    Anyway, you can't copy dll's out of the GAC - at least not through Windows Explorer.  Open up a command prompt and navigate to C:\WINDOWS\assembly (this is the NTFS path to the GAC).  SqlClrProvider is an MSIL assembly so you'll find it under GAC_MSIL.  Dig up the directory path for that assembly name and you'll find a real live dll!  It is xcopy deployable for my needs (restarting SQL Server during an install) but I'm guessing since MS has a nice msi for these things they want you to use them as pre-reqs, BUT you can still get around it by digging through the gac and deploying with your app.

     


    Fred
    • Proposed as answer by ZhaoPenpal Wednesday, September 05, 2012 2:04 PM
    Friday, January 23, 2009 11:27 PM
  • I'm trying to backup the remote sql server database to my local machine. So I copied the Microsoft.SqlServer.SqlClrProvider.dll to my bin folder (along with the other required dll's) but the object browser doesn't show a namespace to use to register the assembly. What to do?

    I also installed the SQL 2008 SMO package on my local machine along with CLR Types package. They installed successfully but I don't know what to do with them after the install. They don't seem to have made any difference. 
    Saturday, March 28, 2009 5:36 PM
  • The fix is to install the SQL 2008 SMO package on the destination machines.  You can find the installer on the following link:

     

    http://www.microsoft.com/downloads/details.aspx?FamilyId=C6C3E9EF-BA29-4A43-8D69-A2BED18FE73C&displaylang=en

     

    Before you can install SMO 10, you will need to install the 2008 CLR Types package onto the machine as SMO is dependant on the CLR Types which can also be found on the link above.

     

    EDIT:

     

    The other thing to do, is to Add A Setup Wizard to the Solution as a new project:

    1. Right Click on the Solution in the Solution Explorer
    2. Click Add
    3. Select New Project.
    4. Expand Other Project Types and Click Setup and Deployment
    5. Double Click Setup Wizard
    6. Provide a Name for the Project and click ok
    7. Click Next
    8. Click Create a Setup for a Windows Application
    9. Click Next
    10. Check Primary Output from <ProjectName>
    11. Click Next
    12. Click Next
    13. Click Finished.

    This will add the needed Dependencies into the Setup Project, including the needed SMO 10 Assemblies from the GAC.  These will then be copied to the Application Install folder when setup runs, allowing the app to run.

     What do I do if I have SQL Server 2005, not 2008?
    Wednesday, September 30, 2009 8:01 PM
  • You can Find the DLL  in

    C:\WINDOWS\assembly\GAC_MSIL\Microsoft.SqlServer.SqlClrProvider\10.0.0.0__89845d
    cd8080cc91>
    Thursday, October 29, 2009 8:04 PM
  • I have one project called script updater. What it does is will have all the latest db script and it will excute the script in SQL 2008 and SQL 2005(Client mahcine). But i have added the SMO reference of SQL2008 to the project. It was running where SQL2008 is installed but was failing where SQL2005 is installed. How to execute script on SQL2005 using SQL 2008 refrence????


    Thanks in Advance

    Senthil

    Monday, November 30, 2009 6:08 AM
  • When you are already using a SETUP project , then the fix is not to install the  smo package !!

    BTW the setup project does NOT correctly detect the neccessary dependencies for BatchParserClient !!!

    It is MIA  !!

    I manually added it to my setup project.  When I did so it sucked in BatchParser as a dependency.

    Now My msi installer gets a new funky error about BatchParser missing dependencies or being badly configured ???

    Whats up with that ??? 

    I thought .net was supposed to magically solve all the stupid dll version ____ ,  but it has only made it worse

    because when some Unamed peoples release updates and patches they do not update the version string

    Which throws the entire GAC technology out the window and right smack back into the middle of dll ____ all over again

    My bosses call these funny people MickySoft :) :)

     

     

    Monday, December 07, 2009 11:40 PM
  • I want to know   IS there a detailed solution  to resovle this question 
    Wednesday, September 05, 2012 2:15 PM
  • The accepted answer tells you how to create a setup solution. Build the setup solution. then take the setupexe and setup.msi and set it up. Once it is setup all the dll will be in the Program Files folder.
    Wednesday, August 21, 2013 10:03 PM