ygoe
ygoe

Reputation: 20364

What SQLite NuGet package do I need

There's a long list of options to choose from on the http://system.data.sqlite.org website. I always prefer the static builds because you never know what other runtimes the dynamic builds require. For my current project I only need the 32-bit DLL because the application currently only runs in 32 bit mode. So I basically just need the single mixed-mode static DLL.

There are a small number of NuGet packages. One of them is System.Data.SQLite.Core but it installs two different DLLs, the MSIL and the native parts, and the latter twice in x86 and x64 subdirectories. The other is System.Data.SQLite.x86 but that depends on LINQ and EF which I won't use.

Is there another hidden package that just contains the one DLL I need? Something like System.Data.SQLite.Core.x86? I don't want to include the file directly in the Git repository so it won't grow too much with every update of that library.

And do the NuGet packages contain the static or dynamic build? I need to know that to setup my installer accordingly, or the program may fail on some computers without warning. The package description really doesn't say much about its contents.

SQLite comes in flexible configurations, and I think the only way to answer that is to have a wide offering of NuGet packages.

Upvotes: 4

Views: 2437

Answers (1)

fedeteka
fedeteka

Reputation: 963

I use this:

Tools – NuGet Package Manager – Package Manager Console Type Install-Package System.Data.SQLite
and press Enter

On the code just write

Imports System.Data.SQLite

That's all I need for a working SQLite on Visual Studio

Upvotes: 4

Related Questions