On Aug 23, 2018, at 4:01 AM, 小旭未来 <[email protected]> wrote:
>
> Hello,I installed "System.Data.SQLite.Core (1.0.109.1)" in my project, but
> when I using "System.Data.SQLite", it throw an exception.
> FileNotFoundException: Could not load file or assembly 'System.Data.SQLite,
> Version=1.0.109.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139’.
Confirmed. Problem reproduction steps:
$ dotnet new console -n x
$ cd x
$ dotnet add package System.Data.SQLite.Core
Edit Program.cs per below
$ dotnet run
In Program.cs, add "using System.Data.SQLite;” at the top and replace the
contents of Main with:
var db = new SQLiteConnection("Data Source=hello.db");
var c = new SQLiteCommand("SELECT 1", db);
var r = c.ExecuteScalar();
db.Close();
The program builds just fine, but it fails at runtime. It doesn’t fail if you
build it without modifying Program.cs to make use of the library first.
_______________________________________________
sqlite-users mailing list
[email protected]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users