-1

I used sqlite-net library and I was creating sqlite connection similar to this : var db = new SqliteConnection(path); But Sqlite-net Extensions demand using Sqlite.Net.SqliteConnection that needs as a first parameter ISQlitePlatform and I didn't know what should I pass there for Windows 7 platform . https://github.com/praeclarum/sqlite-net

ig-melnyk
  • 2,769
  • 2
  • 25
  • 35
  • is there not one for the full .net framework? – Daniel A. White Feb 12 '15 at 12:55
  • @DanielA.White what do you mean? I am talking about this lib - https://github.com/oysteinkrog/SQLite.Net-PCL – ig-melnyk Feb 12 '15 at 13:02
  • 1
    Please provide all relative info, don't force us to guess. Obviously you are **not** using [System.Data.SQLite](http://system.data.sqlite.org/index.html/doc/trunk/www/index.wiki). It looks like you are using the [SQLite.Net PCL](https://www.nuget.org/packages/SQLite.Net-PCL/) package which requires another platform-specific implementation package. So the question is, where is the implementation package for Windows? – Panagiotis Kanavos Feb 12 '15 at 13:02
  • @PanagiotisKanavos have I ever said that I am using System.Data.SQLite? There 's nothing to guess - all details are provided. – ig-melnyk Feb 12 '15 at 13:07
  • You mentioned "SQLite.Net", not "SQLite.Net PCL". SQLite.Net is essentially the name used for System.Data.SQLite. There is another project called "SQLite-Net" by Tim Heuer that has twice the downloads of the one you used. Finally, another "SQLite-net" is a dead project, from which "SQLite.NET PCL" was forked. The github site provides a link to all implementation packages – Panagiotis Kanavos Feb 12 '15 at 13:12
  • @PanagiotisKanavos I said I am using sqlite-net, not Sqlite.Net . – ig-melnyk Feb 12 '15 at 13:14
  • That's Tim Heuer's package, not the one you posted. Check the exact package names and links – Panagiotis Kanavos Feb 12 '15 at 13:19
  • @PanagiotisKanavos okay,I made a small mistake in comments providing the wrong link. Everything including libraries that I am using were provided in the original question – ig-melnyk Feb 12 '15 at 13:21
  • You have to be specific, especially when using uncommon packages, to avoid downvotes and close votes. I didn't downvote by the way, I guessed something was fishy and tried to find out. It isn't a small error, when you mention the wrong library – Panagiotis Kanavos Feb 12 '15 at 13:22
  • Let us [continue this discussion in chat](http://chat.stackoverflow.com/rooms/70791/discussion-between-ig-melnyk-and-panagiotis-kanavos). – ig-melnyk Feb 12 '15 at 13:22

1 Answers1

2

You need to add the Win32-specific package to your solution, SQLite.Net PCL - Win32 Platform and pass an instance of SQLitePlatformWin32 to the connection constructor.

Please note that SQLite.Net PCL is relatively obscure at this time, with half the downloads of the SQLite-net package by Tim Heuer, and 1/10 of the downloads of what most people consider SQLite.Net, the System.Data.SQLite package.

To avoid confusion, it would be better if you specified explicitly the package you mean, including the link to it.

Panagiotis Kanavos
  • 120,703
  • 13
  • 188
  • 236