Justin,
I got rid of those replace functions and omitted the quotes.
My formula is now like this
IF(FIND("{{22.CNPJ}}",{CNPJ Empresa}),{CNPJ Empresa},IF(FIND("{{22.E-mail}}",{Email Contato 1}),"{{22.E-mail}}",IF(FIND("{{22.E-mail}}",{Email Contato 2}),"{{22.E-mail}}")))
in image https://share.getcloudapp.com/geuYDgLX
yet my formula isn’t coming through, as you can see here https://share.getcloudapp.com/YEuv6ZbZ it should find the email in the {Email Contato 2} field.
but when I try a similar formula inside airtable it is working and returning the right email in the 2nd contact email field.
The formula that works in airtable is the following:
IF(FIND(“00000000”,{CNPJ Empresa}), “CNPJ Empresa”, IF(FIND(“lucaseatp@gmail.com”, {Email Contato 1}), “Email Contato 1”, IF(FIND(“lucaseatp@gmail.com”, {Email Contato 2}), “Email Contato 2”,"")))
It is the same example, having the right answer in a rollup field in the {Email Contato 2}, so all IF’s functions are working well in airtable and not finding in integromat… any thoughts?
Sorry for the delay. Our move is in two days, and I’ve been busy prepping.
After looking at this again, I think that I misunderstood your original goal. By searching to find either the CNPJ in the {CNPJ Empresa} field, or the email address in one of the two email fields, you’re actually trying to end up with a matching Airtable record, which will be processed in the rest of the scenario. Is that correct? If so, then the design of the formula is definitely wrong, at least in terms of how it should be designed specifically for use in Integromat.
The Formula field in the Airtable module in Integromat isn’t used in quite the same way as you’d use it in Airtable itself. In the latter case, you’re typically returning data to display directly in the formula field. However, what you’re trying to do in Integromat is find a matching record (or series of records, depending on your use case), using a formula to determine whether each record in the specified table is or isn’t a match. In other words, you don’t want the data from the field, so your formula shouldn’t return actual field data like it does now. You just need to know if the record matches, so the formula should return either TRUE or FALSE. If it’s TRUE, Integromat will pass the record to the rest of the scenario. If it’s FALSE, it won’t pass.
With that in mind, I believe your formula should be:
OR(FIND("{{22.CNPJ}}", {CNPJ Empresa}), FIND("{{22.E-mail}}", {Email Contato 1}), FIND("{{22.E-mail}}", {Email Contato 2}))
The OR() function will return TRUE if any of the conditions inside it are true, or return a TRUE-equivalent value like a positive number. So if the CNPJ is found in the {CNPJ Empresa} field, or the email address is found in either of the two email fields, the record will be considered a match, and will process accordingly.