ST_InteriorRingN(poly, N)

Returns the N-th interior ring for the Polygon value poly as a
LineString. Rings are numbered beginning with 1. If the argument is
NULL or an empty geometry, the return value is NULL.

URL: https://dev.mysql.com/doc/refman/5.7/en/gis-polygon-property-functions.html

