You need to sign in to do that
Don't have an account?
BobP
Flow Doesnt seem to find Opportunity ID
I have a new flow where i launch from an opportunity to update selected custom object related records. The opportunity is a master detail relationship with the custom object. when i click the select custom button on the opportunity instead of just getting the related records to the opportunity I get all records to that custom object. I've tried everything i can think of with this flow to only retrieve the relate records but nothing seems to work. below is a screenshot of my record choice set. Any help with this would be greatly appreciated.
I created a Flow that does what you're looking for, mine gets the current opportunity, the yoshin products related to an opportunity, allows a user to select them, then allows the user to update the selected yoshin products (One by one if multiple are selected). I've attached screenshots for you to duplicate.
Let me know if you have any questions:
Get opportunity
Get Yoshin Products for that opportunity
The collection var to store the yoshin products
This will be continued as the image limit is being reached so I'll put it in posts of 5 images each. Note that my field (opportunity__c is the field for the master-detail with the opportunity)
All Answers
Have you used a lookup to get an opportunity where the recordId == {!recordId}? where "{!recordId}" is a text variable available for input and output.
Flow should be something like
>Get Opportunity where opportunity Id equals {!recordId} (If you create a variable it recognizes the the API recordId as the current record)
>Get Yushin Product where Opportunity_name__c equals opportunity (The get Yoshin is in you record choice set you're configuring)
Screenshots below:
And here are the variables:
If this helps please mark as best answer to help keep the community clean!
Regards,
Tyler
Can you take some pictures of your flow and variables for me to look at?
Regards,
Tyler
https://thewizardnews.com/2018/06/22/update-only-user-selected-records-from-a-multi-select-list-in-flow/#comment-1761
In your record choice set the "Filter Yoshin Product Records" is the issue
You need to change the Filter from "Get all Yoshin Product records (No Conditions) to Meets Filter Criteria. Then have the criteria be
Field = Opportunity_Name__c (Or whatever field is the opportunities Id)
Operator = Equals
Value = {!OppId.Id}
That makes it so the Opportunity Id associated with the Yoshin product record is equal to the OppId.Id field which is the current opportunities Id therefore only showing the current opportunities related yoshin products.
Let me know if you have any more questions.
Regards,
Tyler
That worked!! my flow is only retreiving records associate with specific Opportunities(THAT"S GREAT!). I'm ruinning into another issue though. After I get records associated with the opp, I have a screen element to update the price field on the product page. After i select the products to update, i click next and my flow goes to the last screen and by-passes the step to update the price field on each product.
FAST LOOKUP: Get_Yushin_Products
Find all Yushin_Product__c records where:
Opportunity_Name__c Equals {!OppId.Id} (00618000009HOQFAA4)
Assign those records to {!SelectedProduct}.
Save these field values in the variable: Id, Name
Result
Failed to find records.
I created a Flow that does what you're looking for, mine gets the current opportunity, the yoshin products related to an opportunity, allows a user to select them, then allows the user to update the selected yoshin products (One by one if multiple are selected). I've attached screenshots for you to duplicate.
Let me know if you have any questions:
Get opportunity
Get Yoshin Products for that opportunity
The collection var to store the yoshin products
This will be continued as the image limit is being reached so I'll put it in posts of 5 images each. Note that my field (opportunity__c is the field for the master-detail with the opportunity)
Record choice set for that
The Loop
Make sure you're looping through the collection from the "Get yoshin products".
Here is the loop variable
The screen after the decision
What each type is (Using the loop current name shows which yoshin product you're entering info for just as a advisory note to make sure your users know)
The update price field - note, I just created a variable for default value, you do not have to at all you can leave that blank.
And the update
The value for the update is going to be the API name for the number screen component.
Copy this and your flow will work for you, Let me know if you run into any issues.
Please mark an answer as the best answer to help keep the community clean!
Regards,
Tyler
I've recreated your flow, but for some reason it is not working. When i activate it and go to the opportunity and click the select product custom button all i get is the first screen with not checkboxes, then click next and it goes right to the last screen. I am getting an a message when i try to debug the flow.
Record Choice Set
Record Collection Variable
Product Record Variable
Opportunity Record Variable
When you're getting your opportunity what is the variable you're using in the condition? The one that should be {!recordId}? Is that available for input and output? If not make sure it is. That's what the message is showing.
That was it Tyler, I did'nt have the recordId field checked for input or output. Once i did that it worked. Thank you so much for your patience in working with me. I really appreciate it.