Simply use sqlite3 module
Re-arrange indentation for clarity
Implemented the todo (wait for tables to be present before proceeding)
Waiting for tables is not sufficient. Really need to wait until the bot is ready to connect.