Updated SQLite helper