You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At this time, it appears I have no way of creating a query that does the following:
SELECT Id, Name, MailingLatitude, MailingLongitude
FROM Contact
ORDER BY DISTANCE(MailingAddress, GEOLOCATION(40.7657, -73.9899), 'mi') ASC
Because DISTANCE is not a field, there is no way to call addOrdering to support the above. If this is possible, can someone help me out? If not, I'd like to propose an enhancement.
Thanks!
The text was updated successfully, but these errors were encountered:
That's easy enough when managing your own org, but I'm using this for a managed package where I don't know the object that I'm querying before hand. I'm asking the end user to provide the compound address or geolocation fields as part of setup. I'd prefer that we determine if we can add an additional method to support distance and geolocation adds to the query factory, if possible.
At this time, it appears I have no way of creating a query that does the following:
SELECT Id, Name, MailingLatitude, MailingLongitude
FROM Contact
ORDER BY DISTANCE(MailingAddress, GEOLOCATION(40.7657, -73.9899), 'mi') ASC
Because DISTANCE is not a field, there is no way to call addOrdering to support the above. If this is possible, can someone help me out? If not, I'd like to propose an enhancement.
Thanks!
The text was updated successfully, but these errors were encountered: