Usually, we use some sort of queuing mechanism to connect two devices or processes where the reliability/availability of either end isn’t guaranteed. However, if you have a reliable connection between two devices, the queues can be skipped. The above article does exactly that. It explains how an esp8266 based board can connect to a MySQL server over the network using the TCP protocol. The only limitation being that MySQL has to use a user that is using legacy mode authentication instead of the native authentication that is the default in recent versions.
If you have tried to make this connection successfully, please do let us know via your comments.