Parital solution using sqlite3.