我有点喜欢从c#中使用SQLite。Net,但我似乎找不到合适的图书馆。有吗?官方的?除了使用包装器,还有其他方法使用SQLite吗?


当前回答

Monotouch 1.2版包含了对System.Data的支持。你可以在这里找到更多细节: http://monotouch.net/Documentation/System.Data

但基本上,它允许你在sqlite中使用常见的ADO . net模式。

其他回答

现在还有这个选项:http://code.google.com/p/csharp-sqlite/ -一个完整的SQLite到c#的移植。

我肯定会选择System.Data.SQLite(如前所述:http://sqlite.phxsoftware.com/)

它与ADO是一致的。NET (System.Data.*),并被编译成单个DLL。没有sqlite3.dll -因为SQLite的C代码嵌入在System.Data.SQLite.dll中。一点托管的c++魔法。

来自sqlite.org的人们已经接管了ADO的开发。净提供者:

在他们的主页上:

This is a fork of the popular ADO.NET 4.0 adaptor for SQLite known as System.Data.SQLite. The originator of System.Data.SQLite, Robert Simpson, is aware of this fork, has expressed his approval, and has commit privileges on the new Fossil repository. The SQLite development team intends to maintain System.Data.SQLite moving forward. Historical versions, as well as the original support forums, may still be found at http://sqlite.phxsoftware.com, though there have been no updates to this version since April of 2010.

完整的功能列表可以在他们的维基上找到。亮点包括

ADO。NET 2.0支持 完整的实体框架支持 完全支持Mono Visual Studio 2005/2008设计时支持 紧凑框架,C/ c++支持

已发布的dll可以直接从站点下载。

以下是我能找到的:

managed-sqlite SQLite。净包装 System.Data.SQLite

来源:

sqlite.org 其他的海报

Mono带有一个包装。https://github.com/mono/mono/tree/master/mcs/class/Mono.Data.Sqlite/Mono.Data.Sqlite_2.0提供了以.net友好的方式包装实际SQLite dll (http://www.sqlite.org/sqlite-shell-win32-x86-3071300.zip在下载页面http://www.sqlite.org/download.html/上找到)的代码。它可以在Linux或Windows上运行。

这似乎是所有世界中最薄的,可以最大限度地减少对第三方库的依赖。如果我必须从头开始做这个项目,我就会这样做。