cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
saturation
Level: Powered On

Conditional Statement Needs to Check 2 Separate D365 Entities

I have a conditional statement that requires checking 2 different entities, then sets the Company Type if the conditions are true. Here's basically how it goes..

 

If company type=prospect AND loan stage=terms, set the company type=lead

 

I'm able to check 1 entity for its value, but I can't seem to figure out how to check 2 different entities before updating the company type value? Can someone help?

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: Conditional Statement Needs to Check 2 Separate D365 Entities

Hi @abm ,

 

Please refer to screenshot below to create the flow:

1.png 

Best regards,

Alice       

 

Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

10 REPLIES 10
Super User
Super User

Re: Conditional Statement Needs to Check 2 Separate D365 Entities

Hi @saturation 

 

Could you post your flow screenshot?

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!



saturation
Level: Powered On

Re: Conditional Statement Needs to Check 2 Separate D365 Entities

Here's the flow without the Company entity. It checks the loan entity for a stage, then updates the company type (which you can't see but it's in the update section). But I need it to check the loan entity for a stage, but also check the company type to see if it's a 'prospect' and if it meets both conditions, set the company type to 'lead'

 

MS Flow Example.png

Super User
Super User

Re: Conditional Statement Needs to Check 2 Separate D365 Entities

Hi @saturation 

 

Thanks for the screenshot. 

 

So after the condition under the yes you need to do retrieve the second entity record. Then check the condition for company type. To retreive the second entity you need the Id (GUID) of that record. Have you got any relationship between two entities?

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!



admind365
Level: Powered On

Re: Conditional Statement Needs to Check 2 Separate D365 Entities

Yes, the companyid is stored on the loan record. So basically, connect again except to the company table using the companyid from the loan, check that company type, and then do an update record? I guess I was just confused on whether or not you could combine the conditional statements together rather than doing one, then doing the other...I'm a newbie 🙂

Super User
Super User

Re: Conditional Statement Needs to Check 2 Separate D365 Entities

Hi @admind365  & @saturation

 

In this scenario you can't combine in one condition. You need to retrieve it separately. 

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!



Super User
Super User

Re: Conditional Statement Needs to Check 2 Separate D365 Entities

Hi @saturation  & @admind365 

 

If the below reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!



Community Support Team
Community Support Team

Re: Conditional Statement Needs to Check 2 Separate D365 Entities

Hi @saturation ,

 

Please refer to screenshot below to create the flow:

1.png

 

Best regards,

Alice       

 

Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Super User
Super User

Re: Conditional Statement Needs to Check 2 Separate D365 Entities

Hi @v-alzhan-msft , @saturation  & @admind365 

 

The only issue with the below solution is if the first condition is not satisfied (using the triggered context value) then the next step 'Get Record' is an unwanted round trip to database.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!



Community Support Team
Community Support Team

Re: Conditional Statement Needs to Check 2 Separate D365 Entities

Hi @abm ,

 

Please refer to screenshot below to create the flow:

1.png 

Best regards,

Alice       

 

Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

saturation
Level: Powered On

Re: Conditional Statement Needs to Check 2 Separate D365 Entities

Thanks everyone! That last solution worked - Putting the conditional inside the first conditional. Exciting stuff!

Helpful resources

Announcements
firstImage

Better Together Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

firstImage

Incoming: New and improved badges!

Look out for new contribution recognition badges coming SOON!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Community Summit North America

The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Top Kudoed Authors
Users online (8,139)