· Jan 24, 2018

Using the Caché Entity Framework Provider

I am trying to use Entity Framework with Visual Studio 2017. After following the Intersystems documentation ("Using the Caché Entity Framework Provider") I still cannot see the data source in Server Explorer.  Any ideas why?

Discussion (9)2
Log in or sign up to continue

Hello Edmund,

Which Caché version are you using?  I believe that some earlier versions were incomplete.  In particular, when you unzip/extract from folder <installdir>\dev\dotnet\bin\v4.0.30319
do you get 16 items as I do for Caché 2017.1.1.111?

Are Caché and Visual Studio on the same PC?

The instructions call for running setup with a one-time arg -installflags SetupVS.  ***Have other users of EF been able to run these?

What version of Visual Studio?  I have 2015 (14.0), and I found VsDevCmd.bat in C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\Tools.  But instead opened an admin cmd prompt to the indicated directory, and did:  C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE>.\ /setup
This seemed to take a minute or so.  I don't know if this is what finished the setup, but Visual Studio does now offer the Caché Server option.

On my Win10 64-bit...
Local Caché installations are registered here:

and servers here:

ODBC Drivers here:
ODBC DSNs here:

VS2013 data providers here:

VS2015 data providers here:

Do you have similar registry entries?

And, since these are registry changes, you likely need to restart Visual Studio, and perhaps Caché or Windows.

Thanks for the information. I still have not got it to work but I believe the issue is because I am using Visual Studio 2017. If I understand correctly, this version does not use the registry. It may be that the Intersystems setup is not compatible with that version. I would have to try the setup with Visual Studio 2015, but my use is for a secondary tool in which I would prefer to try out Entity Framework with Cache. So I may not test it too soon.

Not sure if you have reviewed this - but I have had to add the provider factory to the machine.config file manually before being able to see the provider in Visual Studio.  It seems this is missed in some of the files.



          <add name="InterSystems Data Provider" invariant="InterSystems.Data.CacheClient" description="InterSystem .Net Data Provider" type="InterSystems.Data.CacheClient.CacheFactory, Intersystems.Data.CacheClient, Version=, Culture=neutral, PublicKeyToken=ad350a26c4a4447c" />

I normally find this in the .NET 2 machine config - and copy it into the other versions as needed.