Adds password entry function to script, cursor now connects to database.