ST_FrechetDistance(g1, g2 [, unit])

Returns the discrete Fréchet distance between two geometries,
reflecting how similar the geometries are. The result is a
double-precision number measured in the length unit of the spatial
reference system (SRS) of the geometry arguments, or in the length unit
of the unit argument if that argument is given.

This function implements the discrete Fréchet distance, which means it
is restricted to distances between the points of the geometries. For
example, given two LineString arguments, only the points explicitly
mentioned in the geometries are considered. Points on the line segments
between these points are not considered.

ST_FrechetDistance() handles its geometry arguments as described in the
introduction to this section, with these exceptions:

o The geometries may have a Cartesian or geographic SRS, but only
  LineString values are supported. If the arguments are in the same
  Cartesian or geographic SRS, but either is not a LineString, an
  ER_NOT_IMPLEMENTED_FOR_CARTESIAN_SRS
  (https://dev.mysql.com/doc/mysql-errors/8.4/en/server-error-reference
  .html#error_er_not_implemented_for_cartesian_srs) or
  ER_NOT_IMPLEMENTED_FOR_GEOGRAPHIC_SRS
  (https://dev.mysql.com/doc/mysql-errors/8.4/en/server-error-reference
  .html#error_er_not_implemented_for_geographic_srs) error occurs,
  depending on the SRS type.

ST_FrechetDistance() handles its optional unit argument as described in
the introduction to this section.

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

