• Instructions to Ask a Question

    Click on the "Ask a Question" button and select the application for which you would like to ask questions.

    We have 5 different products namely - Pabbly Connect, Pabbly Subscription Billing, Pabbly Email Marketing, Pabbly Form Builder, Pabbly Email Verification.

    The turnaround time is 24 hrs (Business Hours - 10.00 AM to 6.00 PM IST, Except Saturday and Sunday). So your kind patience will be highly appreciated!

    🚀🚀Exclusive Discount Offer

    Just in case you're looking for any ongoing offers on Pabbly, you can check the one-time offers listed below. You just need to pay once and use the application forever -
     

    🔥 Pabbly Connect One Time Plan for $249 (🏆Lifetime Access) -  View offer 

    🔥 Pabbly Subscription Billing One Time Plan for $249 (🏆Lifetime Access) - View offer

Required Field Missing

Status
Not open for further replies.
Your Task History ID
IjU3NjIwNTZmMDYzMzA0MzI1MjZlNTUzNTUxMzY1MTZiNTQzNyI_3D_pc
This is a followup to https://forum.pabbly.com/threads/iterator-not-processing-all-line-items.17640/

The current issue I'm facing is that, when a customer makes a purchase in Shopify and doesn't yet have a Contact in SalesForce, it takes a second or two for a separate workflow to create that customer. (This is not an issue if the Contact already exists.) As a result, I get the following error:

{
"0 > message": "Required fields are missing: [ContactId]",
"0 > errorCode": "REQUIRED_FIELD_MISSING",
"0 > fields > 0": "ContactId"
}

My initial fix for this was to add a Delay and it worked well. But that seems to have broken Iterator. According to Supreme, you can't have a Delay and Iterator. Getting rid of the Delay made Iterator work properly, but now I'm back this issue with the Contact not existing yet. Does anyone have suggestions on how to fix this simply?

Is there perhaps a way to ensure that the workflow that creates a new Contact always runs before the one to create an Opportunity?

Re-executing the workflow after I get the error email works too (maybe I can just set it to 2 attempts instead of 1? I'd rather not waste tasks though).

Or do I have to fit the two workflows together somehow? The problem with the second option is that both workflows are using a router step, so I'm not sure how to have them both. I could probably move the Find Contact step inside the Router, and then duplicate all my routes with extra options based on whether the Contact exists yet... I'm hesitating because I already have 10 Routes and it's getting difficult to parse them (since I can't reorder them). That would only get more troublesome if they need to double to 20.

I'd love it if there's a simpler way. Any thoughts?
 

ArshilAhmad

Moderator
Staff member
Hi @iRestAdmin,

Please try adding a Data Forwarder as the 8th step in your workflow and transfer the data to another workflow. This way, you can divide your use case into two separate workflows. In the new workflow, you can add a Delay as the 2nd step immediately after the trigger step. Following the delay, you can add 'Salesforce: Find Contact' and other Routers from your existing workflow to this new workflow. This is the only workaround I can suggest for now.
 

Attachments

  • 2023-11-22_00h21_21.png
    2023-11-22_00h21_21.png
    94.8 KB · Views: 79
Status
Not open for further replies.
Top