Page 1 of 1

Entity Framework Power Tools Beta 4 and Postgresql 9.3

Posted: Thu 12 Dec 2013 19:40
by tryhp3
I use http://visualstudiogallery.msdn.microso ... 6072eff19d

Reverse Engineer Code First throw:

Code: Select all

System.Data.ProviderIncompatibleException: A null was returned after calling the 'GetService' method on a store provider instance of type 'Devart.Data.PostgreSql.PgSqlProviderFactory'. The store provider might not be functioning correctly.
   at System.Data.Entity.Design.Common.MetadataUtil.GetProviderServices(DbProviderFactory factory)
   at System.Data.Entity.Design.EntityStoreSchemaGenerator.CreateStoreSchemaConnection(String providerInvariantName, String connectionString, Version targetEntityFrameworkVersion)
   at System.Data.Entity.Design.SsdlGenerator.EntityStoreSchemaGeneratorDatabaseSchemaLoader.CreateStoreSchemaConnection(String providerInvariantName, String connectionString, Version& storeSchemaModelVersion)
   at System.Data.Entity.Design.EntityStoreSchemaGenerator..ctor(String providerInvariantName, String connectionString, String namespaceName)
   at Microsoft.DbContextPackage.Handlers.ReverseEngineerCodeFirstHandler.ReverseEngineerCodeFirst(Project project)
What is wrong?

Re: Entity Framework Power Tools Beta 4 and Postgresql 9.3

Posted: Mon 16 Dec 2013 14:34
by Shalex
The Entity Framework support is available only in the Professional edition of dotConnect for PostgreSQL: http://www.devart.com/dotconnect/postgr ... tions.html.

Please specify the exact version (x.x.x.x) and edition of your dotConnect for PostgreSQL.

Re: Entity Framework Power Tools Beta 4 and Postgresql 9.3

Posted: Tue 17 Dec 2013 17:11
by tryhp3
Ok. I use Express version.

Re: Entity Framework Power Tools Beta 4 and Postgresql 9.3

Posted: Tue 25 Feb 2014 20:55
by ACARVALHO
I use Professional edition Trial.

What is wrong?

Re: Entity Framework Power Tools Beta 4 and Postgresql 9.3

Posted: Thu 27 Feb 2014 16:27
by Shalex
@ACARVALHO
Please specify the following information:
1) the exact versions of your Visual Studio and Entity Framework Power Tools
2) the build number (x.x.x.x) of your dotConnect for PostgreSQL
3) the steps we should follow to reproduce the issue in our environment

Re: Entity Framework Power Tools Beta 4 and Postgresql 9.3

Posted: Wed 19 Mar 2014 13:45
by ACARVALHO
1) the exact versions of your Visual Studio and Entity Framework Power Tools
- Visual Studio 2013 RTM
- Entity Framework Power Tools Beta 4
2) the build number (x.x.x.x) of your dotConnect for PostgreSQL
- 7.2.103
3) the steps we should follow to reproduce the issue in our environment
- Right-clicking on a C# project in VS > Entity Framework > Reverse Engineer Code First

error returned:
Unable to find the requested .Net Framework Data Provider. It may not be installed
image error: https://drive.google.com/file/d/0B5_Z5G ... sp=sharing

Re: Entity Framework Power Tools Beta 4 and Postgresql 9.3

Posted: Mon 24 Mar 2014 13:55
by Shalex
Please upgrade Entity Framework Power Tools to the latest (6.1) version and perform these steps:

1) add registration of EF6 provider in app.config as it is described at http://blog.devart.com/entity-framework ... force.html:

Code: Select all

  <entityFramework>
    <providers>
      <provider invariantName="Devart.Data.PostgreSql" type="Devart.Data.PostgreSql.Entity.PgSqlEntityProviderServices, Devart.Data.PostgreSql.Entity, Version=7.3.115.6, Culture=neutral, PublicKeyToken=09af7300eec23701" />
    </providers>
  </entityFramework>
  <system.data>
    <DbProviderFactories>
      <remove invariant="Devart.Data.PostgreSql" />
      <add name="dotConnect for PostgreSQL" invariant="Devart.Data.PostgreSql" description="Devart dotConnect for PostgreSQL" type="Devart.Data.PostgreSql.PgSqlProviderFactory, Devart.Data.PostgreSql, Version=7.3.115.0, Culture=neutral, PublicKeyToken=09af7300eec23701" />
    </DbProviderFactories>
  </system.data>
Replace 7.3.115 here with your actual version (but leave the current revision numbers: *.6 and *.0).

2) right click on the project in Solution Explorer > Manage NuGet Packages > Microsoft and .NET > find EntityFramework (version 6.1.0) and install it

3) rebuild the project

4) the interface in EF Tools 6.1 is changed (http://thedatafarm.com/data-access/firs ... -designer/): run Entity Data Model Wizard > Code First from database, choose dotConnect for PostgreSQL and go through the wizard.