Treasure Data's primary idea portal. 

Submit your ideas & feature requests directly to our product requirements team! We look forward to hearing from you.

Support Geo Function UDF; Calculating distance.

UDF which can calculate distance between 2 point is helpful to analyze Geo data.

- Calculating distance between 2 points: (lat1,long1)~(lat2,long2)

  • Yoshihiro Shimomura
  • Sep 5 2017
  • Shipped
  • Nov 28, 2017

    Admin Response

    This is now possible using the new Presto geospatial functionality provided in the version we now give our customers.

    You can learn more about this functionality here:

    At this time, we do not support setting distance output to be in meters (requested in one of the comments), but we'll consider as a future improvements.

  • Keisuke Noda commented
    November 28, 2017 02:31

    Additionally, It would be great to calculate actual distance in meters if spatial reference id (SRID) can be set.