This plug-in is strictly an exercise in applying MySQL to GIMP by way of Python scripting. Python has an easy way of accessing MySQL data by way of the mysqldb module. You might experiment a little with Python and MySQL before attempting this adapt this code. There is an excellent tutorial on the subject at Tutorialspoint, Python MySQL Database Access.
You should have the MySQL server installed somewhere and have proven you can access it using the basic client from the same machine that is running GIMP. Connecting with MySQL from this GIMP plug-in is exactly the same as connecting from that client. Use the same user, password, host machine and query that works from the command line client. There are default entries for user, password and host that can be ignored. The query can be left to default if you are using the Sakila database. The query is for a VIEW and not a TABLE. The plug-in is coded to limit the query to 36 rows, no matter how many your query retrieves, if you choose to replace the default query.
This plug-in uses a list from the MySQL database to generate two different patterns on a GIMP image. One is a random dispersal of the field entries of randomly varying size and color over the image in a series of text layers. The other pattern, also using a series of text layers, is an array of field entries arrayed in rows and columns all the same color.
This plug-in has been tested on GIMP 2.8 running on XP Pro