ST_IsValid(g)

Returns 1 if the argument is geometrically valid, 0 if the argument is
not geometrically valid. Geometry validity is defined by the OGC
specification.

The only valid empty geometry is represented in the form of an empty
geometry collection value. ST_IsValid() returns 1 in this case. MySQL
does not support GIS EMPTY values such as POINT EMPTY.

ST_IsValid() handles its arguments as described in the introduction to
this section, with this exception:

o If the geometry has a geographic SRS with a longitude or latitude
  that is out of range, an error occurs:

  o If a longitude value is not in the range (−180, 180], an
    ER_GEOMETRY_PARAM_LONGITUDE_OUT_OF_RANGE
    (https://dev.mysql.com/doc/mysql-errors/8.4/en/server-error-referen
    ce.html#error_er_geometry_param_longitude_out_of_range) error
    occurs.

  o If a latitude value is not in the range [−90, 90], an
    ER_GEOMETRY_PARAM_LATITUDE_OUT_OF_RANGE
    (https://dev.mysql.com/doc/mysql-errors/8.4/en/server-error-referen
    ce.html#error_er_geometry_param_latitude_out_of_range) error
    occurs.

  Ranges shown are in degrees. If an SRS uses another unit, the range
  uses the corresponding values in its unit. The exact range limits
  deviate slightly due to floating-point arithmetic.

URL: https://dev.mysql.com/doc/refman/8.4/en/spatial-convenience-functions.html

