views:

1076

answers:

7

Someone asked me this the other day, and I couldn't think of a good answer. Platform portability is completely irrelevant to the project.

In fact, Jet has some features that SQLite does not, namely foreign keys.

So can anyone think why SQLite should be used instead of a Jet database?

+3  A: 

Jet is no longer supported. SQLite is also easier to install since it's one dll that can easily be packaged with your app. Using SQLite also can prevent vender lockin, just because language or cross platform portibility isn't a concern now doesn't mean it won't become one later. For more on Jet's retirement see http://en.wikipedia.org/wiki/Microsoft_Jet_Database_Engine

Jared
The Wikipedia article is filled with bad information. Jet was removed from the MDAC because it was PART OF WINDOWS (from Win2K on). The ACE is just a new version of Jet, fully backwardly compatible with Jet 4 and earlier files. The ACE has a long future, as long as Access exists.
David-W-Fenton
This from Microsoft: "Microsoft has deprecated the Microsoft Jet Engine, and plans no new releases or service packs for this component." (http://msdn.microsoft.com/en-us/library/ms692882.aspx).
onedaywhen
"The ACE has a long future" -- the last release was a disappointment, unless SharePoint integration is your thing, or if multi-valued data types as an engine-supported means of violating 1NF had been on your wishlist for the near decade it took for the Access team to get around to releasing ACE ;-)
onedaywhen
"The ACE has a long future" -- IMO the engine lost more than it gained in going from Jet to ACE i.e. user level security and replication. The best thing about ACE is they finally fixed the DECIMAL data type negative values sort bug :)
onedaywhen
Microsoft again confirming that Jet is deprecated: "Access 2007 provides a new engine based on JET, called the Microsoft Access Engine (ACE Engine), rather than using the deprecated Microsoft JET engine." (http://msdn.microsoft.com/en-us/library/cc811599.aspx).
onedaywhen
ACE is Jet, just under a different name. You've claimed elsewhere that it's not, but it really is, and everyone knows that. If you mean "Jet 4" is deprecated, well, congratulations -- have a cigar. Better if you say what you mean.
David-W-Fenton
No thanks for the cancer stick: I'd prefer if you didn't refer to ACE as 'being Jet'. Jet is deprecated, ACE has a future. Agreed?
onedaywhen
Jet 4.0 is included as part of Windows 2000, XP, VIsta and 7. YOu don't need to install it. So how can SQLLite be easier to install? Granted copying a DLL isn't a difficult install.
Tony Toews
"Jet is deprecated" does not mean "Jet is not supported". Jet is part of Windows, it is supported just as much as any other part of Windows. "Deprecated" does mean Microsoft discourage its use and they would rather not enhance it.
MarkJ
Here's the page on the Access official blog where they confirm that ACE is Jet. It also says Jet is a Windows system component: that means it **is** supported. http://blogs.msdn.com/b/access/archive/2005/10/13/480870.aspx
MarkJ
A: 

Off the top of my head, it's free and cross platform; but more important... do you think it is more stable and scalable that Jet/MS Access/.mdb? Will it be longer lived that its successor (ACE/.accdb)

If it is being used by more than just a couple people, I don't bother with Jet. I go straight to MS-SQL (even the free version of it). It's just not worth the pain of a corrupt DB (which Jet is known for - although maybe they fixed it - I don't want to be their test case though).

CodeSlave
+2  A: 

Cost is not an issue. If your frontend is built in something other than MS-Access, users of the application do not have to pay any fees to have the Jet drivers installed. Visual Studio would include those drivers during your build (At least the pre .NET versions did.).

I'm guessing you have no personal preference and are equally skilled in development in either environment. If your users have already MS-Access licenses and they would like to be able to write their own reports (Oh, God forbid any non-hacker attempting such a tremendous feat!), use Jet.

Jeff O
Given that MS Jet 4.0 is included as part of Windows 2000, XP, Vista and 7 you don't actually need to include the drivers with your install.
Tony Toews
+1  A: 

SQLite is the new Jet. Even if cross-platform is irrelevant to you, it may not be to your customers. Using Jet locks them into Windows and to a no longer supported DB, neither of which are good things. And SQLite works with just about any development environment out there.

Jet is known for having strange corruption issues, so I tend to stay away from it in general.

You can certainly create foreign keys in SQLite, and as of SQLite 3.6.19 foreign key constraints have also been added.

Paul Lefebvre
Jet does not have "strange corruption issues." When improperly managed, files can corrupt. The causes are quite predictable, in fact, and easily avoided.
David-W-Fenton
"When improperly managed, files can corrupt. The causes are quite predictable, in fact, and easily avoided" -- I think the point is that more sophisticated engines manage things properly so that you don't have to.
onedaywhen
Any corruptions issues on a database, manageable or not, is reason enough not to consider it.
Paul Lefebvre
None of my clients experience corruption with their Jet databases. It's been literally years since any of them had any problems.
David-W-Fenton
+2  A: 

SQLite is superior to Jet for the major reason that SQLite is ACID-compliant whereas Jet, unfortunately, isn't. If data integrity is an issue, SQLite offers a much more "robust" platform for your data storage requirements.

SQLite does indeed lack a few features (such as foreign keys), however, these are primarily due to SQLite being specifically developed as being an extremely small and lightweight database that is also serverless.

The serverless aspect of SQLite is also a major benefit over Jet in that nothing needs to be installed on the machine that will run your database. For example, I have used SQLite in an ASP.NET web application and all I needed was the SQLite DLL (in this case is was the excellent System.Data.SQLite drop-in replacement) in my application's "bin" folder, and my database in the application's "App_Data" folder. I could then upload these files to my webhost, and it all "just worked". This is without having to actually install or register anything on the target machine.

A small dowside of SQLite is due to the database being file-based. Database writes will lock the entire database file rather than a specific row or table, whereas Jet will offer you a more granular level of locking. Another small issue, based on the same file-based reasoning, is concurrency, however Jet itself does not offer a high level of concurrency either.

CraigTP
That's not a downside of SQLite. Concurrent/network file writing on Windows is inherently unreliable (sooner or later you'll find intermittent data corruption has been occurring for the last six months so it's in all your backups too), so multiuser systems need a proper database server. SQLite and Jet are for single user scenarios.
rwallace
+8  A: 

Contrary to what other people are saying, Jet is not dead and far from it: ACE is the new version of Jet and it's pretty robust and backward compatible.

Both SQLite and Jet/ACE have their strengths and weaknesses and you need to get more information about the specific points that are important to you and your application.

  • In either case you can redistribute the engine.
  • Jet/ACE is a bit more integrated and supported out of the box in MS tools and Visual Studio.
  • Jet/ACE has more granular locking, which may be important if your app allows multi-users or needs multi-threaded access to the database.
  • Jet/ACE has more features in terms of what you would expect from a database (joins, unions and complex queries).
  • Jet/ACE has a simple migration path to SQL Server, so if your database needs become big, you could move to SQL Server fairly easily.
  • SQLite is cross-platform, so if your app needs to be ported to Linux/Mac under Mono then SQLite is a better choice.
  • the SQLite engine is tighter so redistributing may be easier.
  • datatypes are quite loose in SQLite.
  • SQLite has more liberal redistribution rights (since you can basically do whatever you want with it).

People who say that Jet corrupts databases are stuck in 1995.

In the end, unless your application has some very specific requirements that are pushing the boundaries of either database engines, then it probably doesn't matter which one you chose.
Just use the one that easiest for you to include in your project.

Renaud Bompuis
SQLite also supports joins and unions: sqlite.org/lang_select.html. Maybe you meant that it does not enforce the integrity of foreign keys?
Wim Coenen
A: 

How about a regfree implmentation Checkout the StarSchema-OLAP demo. Hard to believe the performance.

http://www.thecommon.net/3.html