Python interaction with databases
File 'mysql_demo_all.py' demonstrates how to do the following with a MySQL database using Python:
- Connect to MySQL as root user using mysql.connector
- Get the current MySQL version
- Get the MySQL users
- Delete a MySQL user
- Create a MySQL user
- Create a database
- Grant permissions to a MySQL user for a database
- Get the current MySQL user
- Create a new table for a datbase
- Show all of the tables
- Show all of the tables and the engine information for a database
- Show detailed information about a table status
- Show a table structure
- Insert data into a table
- Query a table
- Repair a table
- Delete a table, database, and user.