Generic DAO for SQLite databases.