How to install Npgsql as a data provider for ADO.NET Entity Framework?

ado.net entity-framework npgsql postgresql visual-studio

Question

I have read all that I can find, but no luck. In Visual Studio 2015 Community, here is what I did (with no luck):

  1. Ran: Setup_NpgsqlDdexProvider. This installed Npgsql 3.0.7 and EntityFramework 6.0.0. It also installed Npgsql 3.0.7 in the GAC and the machine.config.
  2. install EntityFramework6.Npgsql
  3. Updated the Npgsql (with Nuget) to version 3.1.6
  4. Updated the EntityFramework to version 6.1.3
  5. Updated the GAC to Npgsql 3.1.6
  6. changed the machine.config at %SystemRoot%\Microsoft.NET\Framework\v4.0.30319\CONFIG and %SystemRoot%\Microsoft.NET\Framework64\v4.0.30319\CONFIG to Npgsql version 3.1.6

When I go to add the ADO.NET Entity Data, I check model from the database. Set the connection (it tests good). Upon returning from the connection window, the Wizard closes immediately.

How are the newest versions of EntityFramework6 and Npgsql installed for ADO.NET?

TIA

1
2
7/31/2016 7:09:12 AM

Popular Answer

Everything is described here, step by step on the page. Below is a link to github: How to setup NpgsqlDdexProvider 3.1.

I use Visual Studio 2015 and the database server PostgreSql 9.4. I installed Npgsql-3.1.8.msi who installed library Npgsql.dll in the GAC:

C:\Windows\Microsoft.NET\assembly\GAC_MSIL\Npgsql\v4.0_3.1.8.0__5d8b90d52f46fda7

and installed NpgsqlDdexProvider-3.1.0.vsix that allows you to add a connection string under VS in Server Explorer for PostgreSQL.

It's work perfectly for me.

Server Explorer - add connection

0
3/27/2017 8:48:08 AM


Related Questions





Related

Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow
Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow