cancel
Showing results for 
Search instead for 
Did you mean: 

SFDC Opportunity product Related List

johnw
Executive Chef I
Executive Chef I

I have created a Recipe in pilot a step

 

gets a related list from Opportunity Products in salesforce (which is a list of all the SKUs in an opportunity)

I then have a step 

Batch Sales Order in Epicor Kinetic (batch)  (Which creates a Sales order and loads all the SKus)

this is super cool

BUT we have 2 different companies in Epicor so I would like to do this exact thing but say 5 of the SKUs are from company 1 and 4 are for company 2

I created a field in SFDC so the opportunity product record would have company 1 or two but I can't figure out how to get the records with the condition for company 1 or 2.

anyway to do the get with conditions? I don't see a get action that has conditions options

 

2 ACCEPTED SOLUTIONS

rachelnatik
Deputy Chef III
Deputy Chef III

Hi! You need to create a loop and iterate over the product list retrieve. Then, in the loop you will have an if/else condition. If Product Company = 1, proceed with X. Else - proceed with Y. 

X & Y executions are essentially the same. But going to different Epicor Companies. 

The use case guide and activity in this module can be helpful: https://academy.workato.com/working-with-databases

View solution in original post

javier-riesco
Workato employee
Workato employee

Ok @johnw , just a quick comment. In the proposed solution, you are iterating over each of the Opportunity Products instead of creating the Sales Order in Epicor in batch, right? This solution, depending on the number of Opporunity Products and Sales Orders may consume a large number of tasks. My question is, instead of getting all the Opportunity Products in one action, have you tried to make 2 different searches filtering by Company using one of the following actions:

javierriesco_0-1702652246652.png

If you are using the "Search records" Action (simpler), you should be able to see the newly created custom field for Company in Salesforce. Ensure that the user you are using in the Workato SFDC connection has permission to access this field. Additionally, don't forget to refresh the recipe schema.

By obtaining the results in this manner, using two separate lists, you will be able to create the Sales Order in Epicor in batches through two different actions. This approach will require fewer tasks compared to the previous method.

Regards

View solution in original post

10 REPLIES 10

As far as step 1) this is my confusion the “Get related lists tep” doesn’t allow me to filter I was hoping there was a conditions option

johnw_1-1702640951683.png

 

 

Same on step 2… within batch add there is no way to filter on which record to add either… or at least I don’t see the “Conditions” options I have seen on other steps

javier-riesco
Workato employee
Workato employee

Hi @johnw , can you share your recipe (using the Sharing option) so we can take a look at it?

johnw
Executive Chef I
Executive Chef I

thanks...  I went through the link that @rachelnatik suggested and that I had missed previously and that was exactly what I needed... 

javier-riesco
Workato employee
Workato employee

Ok @johnw , just a quick comment. In the proposed solution, you are iterating over each of the Opportunity Products instead of creating the Sales Order in Epicor in batch, right? This solution, depending on the number of Opporunity Products and Sales Orders may consume a large number of tasks. My question is, instead of getting all the Opportunity Products in one action, have you tried to make 2 different searches filtering by Company using one of the following actions:

javierriesco_0-1702652246652.png

If you are using the "Search records" Action (simpler), you should be able to see the newly created custom field for Company in Salesforce. Ensure that the user you are using in the Workato SFDC connection has permission to access this field. Additionally, don't forget to refresh the recipe schema.

By obtaining the results in this manner, using two separate lists, you will be able to create the Sales Order in Epicor in batches through two different actions. This approach will require fewer tasks compared to the previous method.

Regards

ok this is what I was looking for... I think this will work better because I was wondering what was going to happen with tasks... I was hoping that each iteration of adding to the list wasn't going to be a task... but you confirmed my fear