The Design of Software (CLOSED)

A public forum for discussing the design of software, from the user interface to the code architecture. Now closed.

The "Design of Software" discussion group has been merged with the main Joel on Software discussion group.

The archives will remain online indefinitely.

asp.net with sqlite

Would it be possible to get an ASP.NET application to use an sqlite database in a file? The client side uses sqlite database and it would be great if I could directly hook into these files from the server side (the files will be uploaded to the server).

I am thinking it would work, but just thought I'd use a lifeline and poll the audience.
webbie
Tuesday, May 13, 2008
 
 
The answer here is it depends. SQLite does not cope very well with multithreaded scenarios where multiple clients try to write to the same database at the same time. But your app may be able to deal with this or maybe it is a read-many write-few scenario. You could also explore having MySQL in the server as it's SQL flavour is pretty close to SQLite's.

Having said this, SQLite works perfectly in ASP.NET and in any other environment, it is just not the best tool for server side multithreaded applications.
JSD Send private email
Wednesday, May 14, 2008
 
 
i've used sqlite with multi-user web apps without issue. the  problem with shared files of any type (including sqlite) lies in the operating systems locking mechanisms. *nix has problems with this and Windows too. Windows specifically doesn't want you to do it. they want you using client-server technologies when you share databases across a network. web apps aren't an issue in multi-threaded or multi-process apps if the database file and the program are both on the web server. this, obviously, leads to a scaling problem. but, depending on your use sqlite can be perfect for this.

unless you're doing massive inserts simultaneously from within transactions i wouldn't worry about multi-user writes; sqlite is pretty solid.
-don
Don Dickinson Send private email
Wednesday, May 14, 2008
 
 
> multiple clients try to write to the same database

This shouldn't be an issue. Each client/user has his own database file. The files are not shared among multiple users.
webbie
Wednesday, May 14, 2008
 
 
Then you will be perfectly fine with it. SQLite is a great database.
JSD Send private email
Thursday, May 15, 2008
 
 
SQLite works fine with multiusers - no problems. as long as database is on the same computer as web-server, multiple readers/single writer locking will work correctly. what people here are talking about applies only when web-server and database files are on different computers and you use standard file sharing protocol, that might corrupt database because locking doesn't work properly.

I think SQLite is terrific choice for your project, it's extremely lightweight and if you're not dealing with some crazy write-only traffic within the same database, SQLite is the best tool for the job.
lubos
Thursday, May 15, 2008
 
 
Thank you for all your input!
webbie
Thursday, May 15, 2008
 
 
Try scimoredb from scimore.com. We support multithreaded applications very nicely, support both embedded like sqlite, but also server scenarios. You get t-sql, ado.net provider, single install, enterprice manager etc.

Questions - drop me a line :)
Scimore Send private email
Wednesday, May 21, 2008
 
 

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics
 
Powered by FogBugz