Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 739
  • Last Modified:

How well does SQLite perform as an in-memory database?

I have read quite a bit of positive and negative things about SQLite, it seems that some people hate it because of problems, and others love it because it runs to well!?!?

Can anyone tell me of their experiences with SQLite, I'm wondering if I could use it to run a small in-memory database, a few tables with a few hundred rows max.
0
ShaunDumas
Asked:
ShaunDumas
2 Solutions
 
cyberkiwiCommented:
SQLite should serve quite well as an in-memory database in most cases.
It is one among many alternative, for .Net you may consider plain xml files for a few hundred rows or even SQL Server Ce.
SQLite has some quirks and limitation that you just have to get use to, such as,

putting strings (accidentally) into integer columns is not a bug
http://www.sqlite.org/faq.html#q3

The SQL syntax supported is also pretty basic, but if you can get by with simple, then you're set to go.
0
 
Kent OlsenData Warehouse Architect / DBACommented:
Hi Shaun,

My experience is that depends on what you're trying to do.

I use SQLite in several applications, but the data is 10s of thousands of rows scattered over several tables.  SQLite allows me the ability to treat it like "a real database", particularly the ability to add queries and reports with standard SQL.  It's not a true "in memory" usage as data is read/written from/to the database (disk) as needed.

If your data is relational, that is the data in one table is related to data in another, SQLite might be the way to go.  On the other hand, if all you're trying to do is store and manage a couple of hundred rows of data you might be better served keeping the data in an array or vector.  SQLite is about 100,000 lines of source code and that's quite a bit to add to a project just to manage a small amount of data.


Good Luck,
Kent
0
 
ShaunDumasAuthor Commented:
Great insights, thanks!
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now