none
Microsoft.SqlServer.BatchParser

    Question

  • I have recently upgraded to Visual Studio 2013 and in the process, removed the Visual Studio 2010 install. In my solution I have a number of .sql files that contain database upgrade commands. Since upgrading I have been unable to edit these files getting an error that Microsoft.SqlServer.BatchParser version 12.0.0.0, publickeytoken 89845dcd8080cc91 could not be loaded. I have read various threads and checked that both the 64 bit and 32 bit versions of this dll are in C\Windows\assembly. However, none of them is version 12.0.0.0 - they are all earlier (9 & 10).

    I've also tried re-installing the Management Objects but it won't let me, saying there is already a higher version installed.

    Any suggestions please?

    Thanks

    Steve

    Monday, December 21, 2015 12:48 PM

Answers

  • Sorry - been on holiday and just re-engaged on this topic. The solution has multiple projects (all C#) but this is the relevant one:

    I've tried using Notepad as an alternative editor but it doesn't allow me to save back the changes as Visual Studio has the file locked in read-only mode. However, if I use the Open With > Source Code Text Editor then I can edit it within VS and it will save it so I can at least get on with the development!

    Regards

    Steve

    Sunday, January 03, 2016 12:50 PM
  • @ Steve,

    >>However, if I use the Open With > Source Code Text Editor then I can edit it within VS and it will save it so I can at least get on with the development!

    So you mean that your app works well now, am I right? If so, would you please make the helpful reply as the answer? So I could really help you close this case.

    Of course, if you have other VS IDE usage issue, feel free to let me know:)

    Have a nice day,

    Jack


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    • Marked as answer by Stephen Viney Wednesday, January 13, 2016 11:59 AM
    Monday, January 04, 2016 8:22 AM
    Moderator

All replies

  • Hi Steve,

    >>Microsoft.SqlServer.BatchParser version 12.0.0.0, publickeytoken 89845dcd8080cc91 could not be loaded.

    I did some research for this issue, like the following cases:

    SQL Server 2005:

    https://social.msdn.microsoft.com/Forums/vstudio/en-US/4c7170b8-6c29-4c1a-b833-9786a046d92c/could-not-load-microsoftsqlserverbatchparser?forum=sqlsmoanddmo

    SQL Server2008 or others:

    https://social.msdn.microsoft.com/Forums/vstudio/en-US/db915423-068c-41ff-946a-a03e82232957/microsoftsqlserverbatchparser-failed-to-load?forum=sqltools

    http://stackoverflow.com/questions/537613/sql-server-smo-complains-of-missing-dll

    It seems that the SQL Server 2005 uses the 9.0 version, SQL Server2008 uses the 10.0 version, so I doubt that the real issue is related to the SQL Server2014/SMO 2014 version.

    Best Regards,

    Jack


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Tuesday, December 22, 2015 7:40 AM
    Moderator
  • Thanks. Quite helpful. It would appear that SQL Server 2014 uses the version 12.0.0.0 of Batchparser. I downloaded the 2014 SMO and ClrTypes packages and installed. Good news is that version 12.0.0.0 is now in my Windows\assembly folder but bad news is, I still have the problem!
    Tuesday, December 22, 2015 4:26 PM
  • Hi Stephen Viney,

    Thanks for your friendly response.

    Just to make this issue clearly, which kind of app did you really develop/create? Could you share me a screen shot about the references folder under your solution explorer window? Whether this dll file is a reference of your current project? Maybe we need to remvoe and re-add it manually or others.

    Not the real SMO experts, but we have to know that whether the real issue is related to your dll references or the .NET Framework version or others since you update the old VS2010 project to the high VS version.

    Of course, we also need to think about the VS2013's compatibility:

    https://msdn.microsoft.com/en-us/library/hh266747(v=vs.120).aspx

    Have nice holidays,

    Jack


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Wednesday, December 23, 2015 8:25 AM
    Moderator
  • Hi Stephen Viney,

    Any update?

    Would you mind letting us know the latest information about this issue?

    Best Regards,

    Jack


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Thursday, December 31, 2015 2:28 AM
    Moderator
  • Sorry - been on holiday and just re-engaged on this topic. The solution has multiple projects (all C#) but this is the relevant one:

    I've tried using Notepad as an alternative editor but it doesn't allow me to save back the changes as Visual Studio has the file locked in read-only mode. However, if I use the Open With > Source Code Text Editor then I can edit it within VS and it will save it so I can at least get on with the development!

    Regards

    Steve

    Sunday, January 03, 2016 12:50 PM
  • @ Steve,

    >>However, if I use the Open With > Source Code Text Editor then I can edit it within VS and it will save it so I can at least get on with the development!

    So you mean that your app works well now, am I right? If so, would you please make the helpful reply as the answer? So I could really help you close this case.

    Of course, if you have other VS IDE usage issue, feel free to let me know:)

    Have a nice day,

    Jack


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    • Marked as answer by Stephen Viney Wednesday, January 13, 2016 11:59 AM
    Monday, January 04, 2016 8:22 AM
    Moderator