我曾经(现在仍然)正在寻找要在 .net (c#) 应用程序中使用的嵌入式数据库。警告:应用程序(或至少数据库)存储在网络驱动器上,但一次只能由 1 个用户使用。 现在,我的第一个想法是SQL Server Compact edition。那确实很好地集成了,但是它不能脱离网络运行。 Firebird似乎也有同样的问题,但 .net Integration 似乎并不是真正一流的,而且在很大程度上没有记录。 Blackfish SQL看着挺有意思的,不过.net版没有试用。定价也可以。 任何其他建议可以很好地与 .net 一起运行并且不需要实际安装服务器软件就可以在网络上运行的东西?


在阅读您的问题时我想到了SQLite ,而且我很确定如果您一次限制 1 个用户,则可以从网络驱动器访问它。 .NET 上的 SQLite - 在 3 分钟内启动并运行
我推荐 Advantage Database Server (www.advantagedatabase.com)。它是一个成熟的嵌入式数据库,具有强大的支持,并且可以从除 .NET 之外的许多开发语言访问。“本地”版本是免费的,以 DLL 的形式在您的应用程序中运行,不需要在服务器/网络共享上安装,并支持所有主要的数据库功能。您可以将数据库和/或应用程序文件全部存储在网络上;它不关心数据在哪里。 免责声明:我是 ADS 研发组的一名工程师。我保证,它很震撼 :)
听起来 ADO/Access 非常适合您的需求。它融入了 MS 堆栈,经验丰富,并且是多用户的。 您可以像这样以编程方式创建数据库: Dim catalog as New ADOX.Catalog Catalog.Create("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=\\server\path\to\db.mdb") 然后您可以使用标准的 ADO.NET 方法与数据库进行交互。
您可以使用嵌入的 firebird,它只是一个您需要随您的应用程序一起提供的 dll。 关于未记录的事情,这不是真的,firebird .NET 驱动程序实现了 ADO 接口,所以如果你知道 ADO,你可以使用 Firebird,基本上你将使用 FBConnection 而不是 SQLConnection 等等,但我的建议是写一个数据访问层并仅在您的代码上使用接口,如下所示: using FirebirdSql.Data.FirebirdClient; public static IDbConnection MyConnection() { FbConnection cn = new FbConnection("..."); return cn; } 这个示例非常简单,但您不需要的比这更多。 我们在所有应用程序中都使用 firebird,没有任何问题,您至少应该尝试一下。
Check out VistaDB. They have a very good product, the server version (3.4) is in Beta and is very close to release.
A little late to the post here.. And VistaDB is already mentioned, but I wanted to point out that VistaDB is 100% managed (since your post was tagged .net). It can run from a shared network drive, and is 1MB xcopy deployed. Since you mention SQL CE, we also support T-SQL Syntax and datatypes (in fact more than SQL CE) and have updateable views, TSQL Procs and other things missing in SQL CE.
Why not use SQL Server 2005 Express edition? It really depends on what you mean by "embedded" - but you can redistribute SQLServer2005E with your applications and the user never has to know it's there. Embedding SQL Server Express in Applications Embedding SQL Server Express into Custom Applications
I'm puzzled. You're asking for an embeded database - where the database itself is stored on the server. that translates to storing the data file on a network share. You then say that SQL Compact Edition won't work... except that if one looks at this document: Word Document: Choosing Between SQL Server 2005 Compact Edition and SQL Server 2005 Express Edition On page 8 you have a nice big green tick next to "Data file storage on a network share". So it seems to me that your first thought was the right one.
There's also Valentina. I cam e across this product when I was working on some Real Basic project. The RB version is very good.
Have you considered an OODB? From the various open sources alternatives I recommend db4o (sorry for the self promotion :)) which can run either embedded or in client/server mode. Best Adriano
This question is now ancient, and a lot has changed. For my specific purposes, LiteDB is the option of choice. It's open source and has a GitHub Repository. Apart from that, SQLite is basically the industry standard for embedded databases. There are attempts to port the code to .NET, but the prime use case involves a native library (e.g., the sqlite Nuget package) and/or a .NET P/Invoke wrapper like Microsoft.Data.SQLite.