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. The plug-in is coded to work with a query against the Sakila MySQL sample dabase, but may work with any query that returns more than one row. This exercise is coded to restrict access to no more than 36 rows (... LIMIT 36).
This little script was inspired by "GIMP tutorial - advanced color correction using sample point and curves" which nicely describes a method to get the color balance of a drawable right.
It expects an active path. If it's not there it exits unceremoniously.
The average RGB values of a 5 pixel radius area around the points in the path are taken and from these color adjustment curves are invoked with the aim to equalize them and thereby get the color balance right.