web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Find Matching Tasks be...
Power Automate
Unanswered

Find Matching Tasks between two Plans in Planner

(0) ShareShare
ReportReport
Posted on by 18

I have two Microsft Planner Plans.  A new plan that was copied from an old Plan.  The copy process allows for you to move a lot of things but it doesn't allow you to select Assignments.  The good part is that, in its current state, All of the buckets, labels, and task names are currently identical.  Which is what I want at the beginning of the plan.  What will change is the checklist items.

 

What I want to do is to have a Flow that can look at the old plan and add the assignees from the old plan to the identical task in the new plan.  Where I seem to be getting stuck is at the point where I should match the task IDs between the plans.  I think it should be a condition where Task Title is identical between the two plans, but that doesn't seem to work right.  Help!Flow Problem.PNG

Categories:
I have the same question (0)
  • Community Power Platform Member Profile Picture
    on at

    Hello,

     

    I'm following your logic and it seems like building a flow based on it should work.

     

    Where is "Apply_to_each_2" in relation to your flow? 

     

    The error seems to reference that second apply to each loop.

     

    thanks,

     

    Kyle

  • autodafey Profile Picture
    18 on at

    That's where I kept getting stuck.  Apply to each Item ID makes sense to me.  But, it seems like it should be conditional on where the Task Title of the Old Plan (since that's where we have assignees) and the Task Title of the New Plan are identical.  Since the titles match but of course the Task IDs don't match.  When I try to put that in as a condition, it freaks out and gives me an error.

     

    I deleted apply to each 2 after the error was generated.  Sorry, I just thought about that and before I screenshot it.

  • Community Power Platform Member Profile Picture
    on at

    Hello,

     

    The error is referencing a second "Apply to Each" loop, though (specifically, one named "Apply to Each 2"). 

    The error does not seem to mention your condition, so I'm going to proceed assuming that the condition is not the immediate issue. 

     

    I have a suggestion based on a hunch, and then if that doesn't work, I have a question and a request from you in order to help us further investigate this:

     

    **Make sure that for whichever "list tasks" action (Old Plan or New Plan) you are referencing in the first Loop, you are referencing the OTHER "list tasks" in the second loop. I know that sounds basic, but it could be easily overlooked.**

     

    If that isn't the issue, please address the below:

     

    1. Is there still a loop in your flow called "Apply to Each 2"?

     

    2. can you please provide a screenshot of the rest of your flow?

     

    Respectfully,

    Kyle

  • Community Power Platform Member Profile Picture
    on at

    @autodafey 

     

    Were you able to resolve the issue?

     

    thanks,

    Kyle

  • autodafey Profile Picture
    18 on at

    Sorry, I just got back to working on this.  So, here's where I am.  I am back at the first apply to each (there is no second apply to each), where I have the Value of the new Plan's task IDs.  What do I do to get the assignees of the old task?  Do I even need a condition?  It seems like all that I need to do is to enumerate the assignees of that task.

  • Community Power Platform Member Profile Picture
    on at

    @autodafey ,

     

    I can't think of anyway to do it other than using two loops.

     

    You have to loop through EACH of the new tasks (first loop) comparing the description of each task against the description of EACH of the old tasks (second loop; nested within the first).

     

    Structurally it should look something like this:

     

    Apply to Each new{

    Apply to Each old{

    if TitleNew equals TitleOld then{

    Update a Task (be sure to update the Task ID of the NEW Task but reference the Dynamic Content for assignments from the OLD Task){

    UpdateTaskAssignments.png

     

    }

    }

    }

    }

     

    I hope this helps.

     

    thanks,

    Kyle

  • autodafey Profile Picture
    18 on at

    I think I have it set up that way and just ran a test, but it's taking over two hours.  Is that usual?  Do I need anything on the no side of this condition?  I tried adding a terminate, but it wouldn't take it.

  • Community Power Platform Member Profile Picture
    on at

    @autodafey ,

     

    Check the output in your flow run history for the run that's taking a long time.

    It will tell you how much time it spent on each step.

     

    You don't need anything on the no side of the condition; if the condition evaluates as false (no), with nothing on that side, the flow just continues (either iterating to the next loop item or ending the flow).

     

    thanks,

    Kyle

  • autodafey Profile Picture
    18 on at

    It like 0s, 2s, 1s, and then the final steps with the task updates has been sitting there for two hours.  Maybe some gateway condition for the loop is problematic?  There are about 480 tasks that it's updating, I just don't have a context for how long that takes.

  • Community Power Platform Member Profile Picture
    on at

    Could you provide a screenshot of that output?

     

    screenshots are very, very helpful in troubleshooting.

     

    Descriptions are nice, screenshots are better.

     

    It doesn't sound like the number of tasks is the issue if it's hanging on the "Update Task" action; it's happening on that first update task. (I'm assuming this since I can't see it)

    It sounds like it's having an issue with actually updating that first task...have any of the tasks in the NEW plan had assignments added?

     

    Also, it might be easier (and safer) to use a test plan while you're building your flow (unless it's no problem to recreate the plan that you're using in production) as you can have fewer items in it and you don't have to worry if the flow overwrites task information or otherwise makes the tasks unusable.

     

    Also, Also: Screenshots.

     

     

    thanks,

    Kyle

     

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 538 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 405 Moderator

#3
abm abm Profile Picture

abm abm 252 Most Valuable Professional

Last 30 days Overall leaderboard