Determine the Distance to a Target POI
Beginner
10 min.
Learn how you can select specific location points via SQL and determine the distance between two points in SAP HANA Cloud, SAP HANA database.
You will learn
- How to transform your location point to a Spatial Reference System
- How to select a target POI from the sample data
- How to determine the distance between two location points
Prerequisites
- You have completed the tutorial Adding Planar Geometries to SAP HANA database in SAP HANA Cloud.
- You have access to the sample spatial data used in this tutorial group.
- Make sure your database instance is running before you start.
In this tutorial, you will learn how to determine the distance to a target Point of Interest (POI). This includes three steps:
- Select a Location via SQL
- Select a Target POI
- Determine distance between two points
Imagine you are done working for today, step out of the office and want to go to a bar in London to grab your well-deserved home-made iced tea.
In this exercise, you will calculate the distance between your location and a POI of the type bar in the table LONDON_POI.



