Realtor Database Distance Between Look-up?

Hey y’all,

New Coda-er here, Love the app and the functionality and I’m already getting my feet wet with all of the cool stuff I can do, but I’ve got a question for how to get started setting up a sweet lookup tool in Coda.

Here’s the current task workflow

  1. Member Posts on Facebook asking for a referral in a certain City (i.e. Atlanta, GA)
  2. I export a list of our paying members from the InfusionSoft database with filters on for that State.
  3. I sort list alphabetically by city name.
  4. Manual process of checking distance from Member City —> Requested City (i.e. Athens, GA to Atlanta, GA.)
  5. If less than a certain value (can be drive time based on google maps api if that’s a thing, or it can be distance based if we’re going actual Geolocation.) We don’t consider those members.
  6. Respond to facebook message with tags of all members that were found/made the cut.

This process happens multiple times a day and I know that I’m exporting the same set of data multiple times, so this is the PERFECT project to get either automated or at least cut down to a simple copy and paste of values into the right table…but I’m an idiot.

Anyone able to point me in the right direction for where to get started building what I’m looking to do? or is this a pipedream due to the goofiness of the task?

Thanks for reading, love you all.

@Nick_D welcome! Coda should be able to do the trick. Depending on how the posts are coming into Facebook, you can use Zapier to bring the request in. I’d also bring in your table from infusionsoft and then connect it in with zapier to keep it updated. Then use Distance() formula to calculate how far it is, and then you could use a Min() formula to find the closest one.

1 Like

Thank you for the reply!

Only question is for that Distance() the input is lat/long. How would I get that from just a city/state table column?

Hmm that is a good question and I don’t have a good answer. GoogleMap() is a hidden formula that comes to mind … maybe trying to send it out to Zapier have it parsed and come back?

Hi @Nick_D, and welcome again,

@Johg_Ananda is right, there is not (yet?) a specific formula or pack providing spatial coordinates from a city.
However, you can build-up/import open data (e.g. from and create your own table one-off, if it’s something viable in your contexts.

Then just refer to this as a simple lookup:

Please, let me know it this makes sense to you.

1 Like