When I try to query data in SSMS v17.3, I get the following error message:
Expected 1 export(s) with contract name "Microsoft.VisualStudio.Utilities.IContentTypeRegistryService" but found 0 after applying applicable constraints. (mscorlib)
I have Visual Studio 2015 and 2017 Community Editions on my machine.
What I have tried:
- Deleted any
ComponentCache
folders fromAppData/Local/Microsoft/VisualStudio
- Repaired SSMS and rebooted
3条答案
按热度按时间l2osamch1#
For SSMS 2018, Delete the ComponentModelCache from the following path
\AppData\Local\Microsoft\SQL Server Management Studio\18.0_IsoShell
For other versions find ComponentModelCache folder from "%AppData%..\Local\Microsoft\VisualStudio" path and delete it.
gzjq41n42#
I had the same problem - the second part of this resolved it for me - change the version # to your version - found on another site
Based on your description, I’m sensing that the issue is with Visual Studio Isolated shell. If you are getting this error in SSMS 2016, I would suggest you delete or rename the ComponentModelCache folder under ”%AppData%..\Local\Microsoft\VisualStudio\14.0\” and ”%AppData%..\Local\Microsoft\SQL Server Management Studio\13.0" see if the issue goes away.
If you have any other questions, please let me know.
ocebsuys3#
Visual Studio gave me the following error: "Export operations (1) with the contract name "Microsoft internal Visual studio.PlattormUliSclutionAttachedCollectio nService2" are expected, but after applying the appropriate restrictions, 0 was found." I could not solve this problem for a long time (the Internet did not help), but then I remembered that I had downloaded the proposed updates for Windows before that. This let me know that the updates may have affected the Visual Studio system. After reviewing the update log, I found "Cumulative Update.NET Framework 3.5 and 4.8.1..." and realized that this is the cause of the error. Therefore, in order for Visual Studio to work, I updated it. And only after that everything worked for me.