Best answer

Is it possible to dynamically choose which field is updated based on trigger data

  • 4 June 2020
  • 1 reply
  • 285 views

I want to trigger an update to a Salesforce object when a Google sheet is updated, where I’m mapping the data from one column into 1 of 6 different fields in Salesforce.  IE, if the Sheets cell A2 contains “Event”, then field Event is TRUE in Salesforce, but if A2 contains “Call”, then field Call is TRUE in Salesforce.

RN, I’m using 6 different look up tables, one for each field - for event field, use lookup table with if A2=Event, then TRUE, otherwise blank.

Is there a better way to do this?

icon

Best answer by Danvers 8 June 2020, 18:38

View original

This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

1 reply

Userlevel 7
Badge +12

Hi @SheEOAdmin! You may have found the best way to do this, though if you’re up for some experimentation, there might be a better way to do this. 

 

In your Google Sheet, you’ll need to add 6 more columns, one for each of the Salesforce fields. Add a formula in each columns that lets you know whether the value should be true or false eg in the ‘Events’ column, add a formula that says ‘If A2 contains event then write TRUE’ 

 

Then in the Zap, map the formula columns to the Salesforce fields. I think that should do the job, but you’ll need to do a bit of testing to make sure that it the true/false value you get from Google Sheets will properly map with the true/false value that you need for Salesforce.