views:

28

answers:

1

I have come across various situations, where I want to store some formatted data in a way such that it can be easily queried.

For example

$ cat so.txt
"question_id": 58640,
"tags": ["polls", "fun", "quotes"],
"title": "Great programming quotes"
"question_id": 184618,
"tags": ["polls", "fun", "comment"],
"title": "What is the best comment in source code you have ever encountered?"
"question_id": 3734102,
"tags": ["c++", "linux", "exit-code"],
"title": "Why cant' I return bigger values from main function ?"
"question_id": 2349378,
"tags": ["communication", "terminology", "vocabulary"],
"title": "New programming jargon you coined?"
"question_id": 3723817,
"tags": ["open-source", "project-management", "failure", "fail"],
"title": "How to make an open source project fail"
"question_id": 3699150,
"tags": ["testing", "interview-questions", "job-interview"],
"title": "Interview question please help"
$

A simple query can be displaying the titles of the questions with tags "C++".

These are the requirements

  • The database has to support just me.
  • It must be able to support all the general SQL type queries. I am familiar with SQL, so the more it is SQL-like, the better.
  • It has to be run locally on my Linux machine running Ubuntu 10.04.
  • Also, since my requirements are minimal, I expect it not to use up too much memory.

What DBMS do you suggest for this purpose?

+1  A: 

the code you posted looks like json. if this is the format you primarily keep your data, it's possible that something like couchdb would be ideal for you? I'm a big fan of it, so I'm biased :)

otherwise, the traditional answer to "light database that only supports me" is SQLite.

Oren Mazor
@Oren: this is just an example format. I plan to manually parse my data before storing it into the database.
Lazer
gotcha. in that case, sqlite is by far the easiest and lightest rdbms
Oren Mazor