implemented database using sqlite3