0

I am trying to use the SQLite-Net Extensions NuGet package in a WinForms application. I have included a reference within a class and am trying to follow the documentation found here:

https://bitbucket.org/twincoders/sqlite-net-extensions

However, in the example, there are a few things that are left out.

var db = Utils.CreateConnection();
db.CreateTable<Stock>();

There is no Utils class, so I figured I would just create my own SQLiteConnection object and the CreateTable extension method would become usable, but that turned out to be false. Can someone tell me what I am doing wrong?

jazb
  • 5,498
  • 6
  • 37
  • 44
JohnWick
  • 4,929
  • 9
  • 37
  • 74
  • i'd recommend using the package from the SQLite Dev team: https://www.nuget.org/packages/System.Data.SQLite – jazb Dec 04 '18 at 03:13
  • @JohnB I have System.Data.SQLite added to my project already, plus the SQLite-Net Extensions package to extend the SQLiteConnection object. – JohnWick Dec 04 '18 at 03:15
  • 1
    they may not play nicely together... – jazb Dec 04 '18 at 03:17
  • the extension say it needs `sqlite-net-plc (>=1.4.118)` – jazb Dec 04 '18 at 03:18
  • 1
    it's all a bit of a mess in the sqllite space so i can understand how easy it would be to get packages mixed up – jazb Dec 04 '18 at 03:20
  • 1
    @JohnB Hey John thanks for the help. It turns out I had System.Data.SQLite and SqliteExtensions both in my using statements, but did not have the Sqlite namespace from the sqlite-net package you mentioned imported as well. It is working now. – JohnWick Dec 04 '18 at 03:23
  • cool - glad to hear – jazb Dec 04 '18 at 03:24

0 Answers0