• I kind of confused on why we need the PyMySQL Python module in the first place (when we already have MySQL).

    Distinguish between MySQL the server and the mysql client. We never talk to the server directly; we always need an intermediary. (This is starting to sound quasi-religious.)

    The PyMysql Python module allows our Python program to talk to the server, just like the mysql client allows a human to talk to the server.

  • Can you over setting up the database, cursors, and connection?

    Sure. The database server already exists; I installed and configured that software long ago. I created database was created earlier this semester, at the same time that I set up your MySQL username and password.

    Your python program connects to the server and uses a cursor to run queries, just like you did with the mysql client.

  • To clarify, do we use cursors to get data from databases and put them in dictionaries or arrays? Can we do this without using cursors?

    Yes, we use cursors to get data from databases. No, there's no other way to do it.

  • What happens if you run more than one cursor.execute('sql query') command before fetching the results? Can you access the output of every result, or will you only fetch output from the most recent query?

    The second query would overwrite the first. If you need to have two simultaneous queries, use two cursors. They're inexpensive.