/MetaDatabaseCourse_MySQL.Connector_Practice

Practicing using the mysql.connector library to connect MySQL database to my python script

Primary LanguageJupyter Notebook

MetaDatabaseCourse_MySQL.Connector_Practice

Practicing using the mysql.connector library to connect MySQL database to my python script

  • The code first establishing the connection to the database.
  • I then run SQL queries from the python script to create the database 'little lemon', which is a fictional resturaunt!
  • I then add my tables and data (again in the mpython script.
  • I then create two connection pools using connection pooling.
  • I then create and test two stored proceduces - PeakHours (which shows the number of bookings per hour) and Guest Status (which assigned a status to a customer based on where their order is at eg. waiting for food, waiting to pay etc)
  • Finally, I go through the exercises set to create more stored procedures and query my database.
  • The code is in a Jupyter Notebook which has already been run - therefore the print statements should be showing without you needing to run anything!