I'm Trying to work with SQLITE database using visual studio 2013. I have installed System.Data.SQLite (x86/x64) 1.0.92 to visual studio. And installed the Setups for 64-bit Windows (.NET Framework 4.5) as well.
It gives me and exception when i'm trying to create database using code first.
SQL logic error or missing database no such table: ****
Cannot create Entity Data Model using existing database. No provider is there to create connection. So Cannot Use Model First
Is there any way to overcome above problems.
Entity framework 6 for SQLITE is not supporting Database/ Table creation when you use code first.
You need to create database manually and create tables using
OR as mentioned in the question Success Scenario, it support the code first with existing database.
I believe there is.
startup useLegacyV2RuntimeActivationPolicy ="true">
(I couldn't insert the XAML code here correctly so check before copying or type it manually)
-In case there is a problem with your connection string use;
public static string ConnectionString = @"Data Source = databasename.db;Version=3; "
The last thing means that I suggest you to use SQLite3.