cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Thanasis
Helper IV
Helper IV

Error: Action 'Apply_to_each_2' must be a parent 'foreach' scope of action 'Condition' to be referenced by 'repeatItems' or 'items' functions.'.'.

Hello I am getting an error  and I would really appreciate some help on this. 

 

I'm trying to create a flow that compares a column in a SPlist with a 365 group and gives me the names that are missing from that list. 

This is what I get:

The inputs of template action 'Condition' at line '1 and column '3552' is invalid. Action 'Apply_to_each_2' must be a parent 'foreach' scope of action 'Condition' to be referenced by 'repeatItems' or 'items' functions.'.'.

 

 This is what I have 

 

Thanasis_0-1642783221551.png

Thanasis_1-1642783331973.png

Thanasis_2-1642783573659.png

Thanasis_4-1642783656541.png

 

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
ManishJain
Solution Sage
Solution Sage

Hi @Thanasis ,

 

Change Items('Apply_to_each_2') to Items('Apply_to_each_3')

 

Thanks

View solution in original post

5 REPLIES 5
ManishJain
Solution Sage
Solution Sage

Hi @Thanasis ,

 

Change Items('Apply_to_each_2') to Items('Apply_to_each_3')

 

Thanks

Thanasis
Helper IV
Helper IV

Thank you @ManishJain  that did help the think is when I run it though, 

 

It gives me names that are in my SPlist, It should only give me the names that are missing from the SPlist ,

 

Any thoughts ?

ManishJain
Solution Sage
Solution Sage

What is coming in the output for MissingNames variable ?

Hello @ManishJain thanks for your help  I was able to figure one part of it. I had to change this

Thanasis_0-1642788958789.png

 

The last part is, before changing the Pagination to 5000

I was getting this 

Thanasis_1-1642789038693.png

 

Now I am getting this 

Thanasis_2-1642789073050.png

Now its reading correctly my SPlist column which so far is 335 , but it doesn't read the group right 

 

There are around 470 people in that group but only reads 100 

 

Any suggestions ?

 

Sorry about that, it was user error, I only did the Pagination for the get items, I didn't do it for List group Members.

 

All good now thank you 

Helpful resources

Announcements
Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Difinity Conference 2022

Difinity Conference 2022

Register today for two amazing days of learning, featuring intensive learning sessions across multiple tracks, led by engaging and dynamic experts.

European SharePoint Conference

European SharePoint Conference

The European SharePoint Conference returns live and in-person November 28-December 1 with 4 Microsoft Keynotes, 9 Tutorials, and 120 Sessions.

Users online (1,901)