ST_Distance + ST_Transform, it works better for datasets that cover large regions such as continents or the entire planet. It is equivalent to PostGIS ST_Distance(geography, use_spheroid=false) and ST_DistanceSphere function and produces nearly identical results. It provides faster but less accurate result compared to ST_DistanceSpheroid.
Geometry must be in EPSG:4326 (WGS84) projection and must be in ==lon/lat== order. You can use ==ST_FlipCoordinates== to swap lat and lon. For non-point data, we first take the centroids of both geometries and then compute the distance.
By default, this function uses lon/lat order since
v1.5.0. Before, it used lat/lon order.Signatures
Parameters
The input geometry.
Return type
A numeric value.

