dotConnect for SQLite Provider not found 5.1.55.0 Pro

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for SQLite
Post Reply
jhsu42
Posts: 1
Joined: Thu 12 Feb 2015 13:46

dotConnect for SQLite Provider not found 5.1.55.0 Pro

Post by jhsu42 » Thu 12 Feb 2015 14:47

Hi, we're experiencing an odd situation on a deployment of our application. We're using the dotConnect for SQLite provider with code-first implementation to create our database files. This works most of the time, however, on some installs, the provider is not found. The libraries are registered in the GAC and the app.config has the above entry in it, but our application fails when trying to create our SQLite databases. The exception that's thrown is as follows:

Code: Select all

Error detected in LaunchProjectDialog in the DbContext./nError Message: No Entity Framework provider found for the ADO.NET provider with invariant name 'Devart.Data.SQLite'. Make sure the provider is registered in the 'entityFramework' section of the application config file.
During our install, we install the dotConnect libraries and set the following entries in the app.config of our host application.

Code: Select all

<configSections>
    <section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework,  Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
  </configSections>
  <entityFramework>
    <providers>
      <provider invariantName="Devart.Data.SQLite" type="Devart.Data.SQLite.Entity.SQLiteEntityProviderServices, Devart.Data.SQLite.Entity, Version=5.1.55.6, Culture=neutral, PublicKeyToken=09af7300eec23701" />
    </providers>
  </entityFramework>
One thing to note is that the particular machine we are having issues on is heavily locked down with restricted security permissions. Are there any system settings that get set during install or needed during execution that may be restricted because of these permission settings?

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Re: dotConnect for SQLite Provider not found 5.1.55.0 Pro

Post by Shalex » Fri 13 Feb 2015 14:52

Additionally, you should register configuration information in the DbProviderFactories section of the *.config file to inform your environment about the existence of the provider factory:

Code: Select all

<system.data>
  <DbProviderFactories>
    <remove invariant="Devart.Data.SQLite" />
    <add name="dotConnect for SQLite" invariant="Devart.Data.SQLite" description="Devart dotConnect for SQLite" type="Devart.Data.SQLite.SQLiteProviderFactory, Devart.Data.SQLite, Version=5.1.55.0, Culture=neutral, PublicKeyToken=09af7300eec23701" />
  </DbProviderFactories>
</system.data>
Replace 5.1.55.0 here with your actual version.
Note that the revision number of provider in the entityFramework section is *.6 but in DbProviderFactories - *.0.

For more information, refer to
http://www.devart.com/dotconnect/sqlite ... yment.html
http://www.devart.com/dotconnect/sqlite ... pport.html
http://blog.devart.com/entity-framework ... force.html

Post Reply