Question

Choose from dropdown Salesforce fields based on text in form field


Userlevel 1

Hello,

I have zaps connecting Facebook Lead Ads, TikTok Lead Ads and other social Media Lead Ads to Salesforce.

I have a task that requires searching a if a form field contains one of the options in dropdown Salesforce fields and set the Action field to that dropdown that value if a match is found.

How can I feasibly do this in Zapier?

Thanks,

 


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

11 replies

Userlevel 7
Badge +11

Hi there @R.A.! 👋


It sounds like you might need to use a Formatter (Utilities > Lookup Table) action for this. When selecting a value (using the custom value option) from a previous trigger or action step for a dropdown menu field you’ll be expected to supply the ID for the option. But the ID for the Salesforce option likely won’t be sent over from Facebook Lead Ads, TikTok Lead Ads etc. So that’s where a lookup table would come in. 

A lookup table could convert the selected option present in the form field into the relevant ID number for the Salesforce option. You can also set a fallback value in the lookup table so if there’s no match found it can output a specific ID that would allow the Zap to assign a certain Salesforce option. We have a guide on how to add a lookup tables to your Zap that you might find useful: Create lookup tables in Zaps.

Hope that helps to get you started. Please let us know if you run into any issues on that at all! 🙂

Userlevel 1

Hi SamB,

Thanks for the tip.

 

Would the Find Record in Salesforce Action be of use here to avoid the manual monitoring of the lookup table?

Userlevel 7
Badge +9

Hey there, @R.A. - you could certainly give it a shot!

As Sam mentioned in order for a Search step to work without the Lookup it would require all the ID’s in Salesforce matching up with those being provided from Facebook Lead Ads, TikTok Lead Ads etc. 

I hope some of this helps! 🧡

Userlevel 1

Hi @christina.d,

 

Thanks for the answer.

 

I can see a “Create Record in Salesforce if it doesn’t exist” option in the “Find Record in Salesforce” Action.

 

Wouldn’t this mean that all leads will be written in Salesforce regardless of the ID matching or not? because it will create a record even if it doesn’t find a match in the IDs.

 

However, I tested this option and gave me the following error:

Appreciate your help here.

 

Thanks,

Userlevel 7
Badge +8

@R.A. For your first question, I believe the answer to this is yes. 

As for your error message, can you please tell me what kind of field type ‘Campaign’ is? 

Userlevel 1

It’s a text field.

 

Userlevel 7
Badge +6

Hi @R.A.,

I’m jumping in to see if I can help!

To better understand the situation and identify the cause of the error, it would be great if you could provide a screenshot of your Zap's configuration. Please capture the entire setup in the screenshot, including the fields in the "Action" section of the action steps. Here’s an example screenshot:

46dd6c0979e3d815d621b8da43084ef1.png
(view larger)

Please don't include personal information in the screenshot, or be sure blur out any personal information.

Thanks! 😊

 

Userlevel 1

 

This is the first Action Step:

 

Second Action Step:

 

Thanks,

Userlevel 7
Badge +6

Hi @R.A.,

Thanks for the screenshot I really appreciate it.

I did some digging on this, and it seems that the error you're experiencing might be related to the settings of your Campaign in Salesforce. Now, I'm not too familiar with what the Campaign settings look like, but based on our notes, I think you should try doing the following in your Campaign settings similar to this:

This usually happens with leads/opportunities, and is due to processes set up in Salesforce. Check the Record Types under Customize > Lead > Record Types and make sure that Read-only is not checked off for any of the profiles you have created.

Here's where to locate Lead Record Type on the Salesforce Sidebar:

b422ad0b48a18e1df092f965f49797df.png
(view larger)

Here's an example of the Record Type Settings, by default, Read-only is checked, kindly uncheck it:
cf6892796b87edccfe963b3becf17078.png
(view larger)

Hopefully, this points you to the right direction.

Userlevel 1

thanks for the above.

Just so I understand correctly, so this would allow Zapier to create a new campaign object in Salesforce f it doesn’t find a match ?

Userlevel 7
Badge +11

Hi again @R.A.

Yes, turning off that Read Only setting for the Campaign object in Salesforce as Ken suggested should help to get rid of the error and allow the Find Record action to create a new campaign if an existing one isn’t found. As long as the Create Record in Salesforce if it doesn’t exist yet? option is selected. 

Want to give that a try and let us know how that goes? Keen to ensure you’re all set here!