Geocoding Map-Only Records
The Dilemma
Accounts and Contacts usually don’t have dates/times so you cannot manually geocode them from DayBack because they don’t show on the calendar; they are usually related to objects (like Event) that already have a date/time.
That’s why for Accounts or Contacts it makes sense to have them as Map-Only sources where you just need a location and geolocation and they will show as pins on the map.
The further issue here is that when a calendar source is set to “Map-Only” you cannot have the Geocode field as a text; it must be a Geolocation field. This means that we cannot use a formula field to build the geolocation since a formula field cannot return a Geolocation type.
In this case where we cannot manually geocode those Accounts or Contacts (nor do we probably want to) and cannot map in a formula field for the Geocode field, how can we get geocodes on these Accounts/Contacts that DayBack can use?
We can use a series of flows to 1. Backfill geocodes on all existing Accounts/Contacts, 2. Update the geolocation field when a new Account/Contact is created, and 3. Update the geolocation field when the address of an Account/Contact is updated.
Prerequisites
- Map Location and Geocode fields in DayBack
-
Instructions on how to do that here: https://docs.dayback.com/article/326-mapping-location-and-geocode-fields
-
- Enable Data Integration Rule in Salesforce
- Enable Data Integration to create geocodes for the object records you want to map.
- Salesforce can generate those geocodes on your Accounts for you. Follow the instructions here to get that data generated: https://help.salesforce.com/s/articleView?id=sales.data_dot_com_clean_admin_automatically_get_geocodes_for_addresses.htm&type=5
- You’ll want to be mindful of which address you are geocoding (either Shipping Address or Billing Address) and you want to make sure that is what is mapped in DayBack.
Backfill Geocodes for Existing Accounts
Once the geocodes exist, we now need to backfill them into the Geolocation field we made for DayBack.
Trigger: One-time Schedule Triggered Flow
Have it run only once and add any conditions you’d like (For example, when Account is active)
Then when you navigate back to DayBack, you'll see pins on the map that represent your Accounts.
Create Geocodes when an Account is Created
Now, moving forward, we need a flow that runs on Account creation so that the Geolocation field for new Accounts is updated and shows on the map in DayBack.
Update Geocodes when an Account Address is Updated
In the unlikely, but still possible, case where the address of an Account can be updated after it’s been created, we’ll need another flow that updates the Geolocation of the newly updated address.
If you need help with this flow, please get in touch about an implementation package for DayBack.