Carrot reference
Functions
nearestLocation()
returns the nearest geographic location to a particular person, group, or address syntax nearestlocation(entity\[, list]) parameters parameter type description entity person docid\ bzrx1mtdjk8cgkaw7ujqj , group docid 7kum4sl wt2y ldfmo6qb , or address docid\ khi0d64z7evk0dsm gjwf the starting point to measure distance from list list docid\ xwh cukhj9waqaefb7h71 optionally, a list of groups, addresses, or persons, to compare against the one that is the nearest geographically will be returned if this parameter is not provided, all locations will be compared return type person docid\ bzrx1mtdjk8cgkaw7ujqj , group docid 7kum4sl wt2y ldfmo6qb , or address docid\ khi0d64z7evk0dsm gjwf whichever entity provided in the list , or whichever group docid 7kum4sl wt2y ldfmo6qb location is closest geographically, will be returned examples nearestlocation(person) returns the nearest location group to the person, inclusive of remote locations and offices nearestlocation(person, person managers) returns which of the person's manager chain lives closest to the person nearestlocation(person, db group find{type\ location and name\ atlanta,boston,orlando}) returns which of the locations matching "atlanta", "boston" or "orlando" is closest to the current person