function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
AbAb 

Calculating Distance between two places

Hello,

How is it possible to calculate distance between two points given the lattitude and longitude.
Also, are there other geolocalization apps i can have a look

Thanks
 
Best Answer chosen by Ab
Alexander TsitsuraAlexander Tsitsura
Hi Sandrine

You can use DISTANCE and GEOLOCATION functions(work in formula)
 
DISTANCE(GEOLOCATION(LAT_1__c,LON_1__c), GEOLOCATION(LAT_2__c,LON_2__c), 'mi')

As a common practice, if your question is answered, please choose 1 best answer. 
But you can give every answer a thumb up if that answer is helpful to you.

Thanks,
Alex

All Answers

Alexander TsitsuraAlexander Tsitsura
Hi Sandrine

You can use DISTANCE and GEOLOCATION functions(work in formula)
 
DISTANCE(GEOLOCATION(LAT_1__c,LON_1__c), GEOLOCATION(LAT_2__c,LON_2__c), 'mi')

As a common practice, if your question is answered, please choose 1 best answer. 
But you can give every answer a thumb up if that answer is helpful to you.

Thanks,
Alex
This was selected as the best answer
karunakarreddy bade 8karunakarreddy bade 8

Hi Sandrine

You can use DISTANCE and GEOLOCATION functions(work in formula)
 
DISTANCE(GEOLOCATION(LAT_1__c,LON_1__c), GEOLOCATION(LAT_2__c,LON_2__c), 'mi')

Thanks,
B.karunakar