Options

ST_ReverseGeocode

Does Vertica geospatial toolkit contain the ST_ReverseGeocode function which reverses geolocation to readable Addresses ?

Tagged:

Answers

  • Options
    moshegmosheg Vertica Employee Administrator

    Not at the current version.
    Please open a support case to explain the business need to prioritize this.

  • Options

    Thank you Mosheg, basically we need to reverse geocode a location , feeding the function the lat/long and getting the address in human readable format

    example:

    SELECT ST_Reverse(ST_Point(-122.0856086, 37.4224082)) AS address;

  • Options
    Bryan_HBryan_H Vertica Employee Administrator

    An issue is that Vertica needs a third-party provider for address lookup. You could write a Python UDSF that takes a Point or (x,y) coordinate as input and calls the OpenStreetMap API to get an address, which you would then return as a VARCHAR (or ROW if you'd like the address components):
    https://wiki.openstreetmap.org/wiki/Nominatim
    ArcGIS and others also provide reverse geocoding API that could be accessed by a UDX.

  • Options
    Bryan_HBryan_H Vertica Employee Administrator

    I've posted a Python UDSF example using GeoPy and Nominatim at
    https://github.com/bryanherger/vertica-python-udx
    Please see the instructions and example under "UDSF example: reverseGeocode" in the README and sample implementation in the reversegeocode folder. It has not been tested at scale beyond the one-time example shown.

  • Options

    @Bryan_H said:
    I've posted a Python UDSF example using GeoPy and Nominatim at
    https://github.com/bryanherger/vertica-python-udx
    Please see the instructions and example under "UDSF example: reverseGeocode" in the README and sample implementation in the reversegeocode folder. It has not been tested at scale beyond the one-time example shown.

    Thank you for your time, this is very helpful

Leave a Comment

BoldItalicStrikethroughOrdered listUnordered list
Emoji
Image
Align leftAlign centerAlign rightToggle HTML viewToggle full pageToggle lights
Drop image/file