cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
dmistry
Level 8

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

@ZachRoberts appreciate the feedback, Just FYI, I am using the same flow solution provided on this thread. The only diffference being, I have three additional choice drop down columns and I want to include them in the select query so its rolled out in email body.

 

Thanks again.

dmistry
Level 8

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

@ZachRoberts, one question, in my case task description contains about 6-7 lines of text so description columns takes up most portion of table in terms of width. Can we restrict the size of such column or maybe apply some word-wrap, padding etc. Please advise, thank you.

dmistry
Level 8

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

@ZachRoberts, I have got this to work. Simply changed the expression formula from item()?['Investor']?['Value'] to item()['Investor']?['Value']

fzer0
Level: Powered On

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

Is there any way to extract all 'AssignedTo' emails for tasks which are assigned to more than one user?

ovis2018
Level: Powered On

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

Has anyone figured out how to correct the error for Append to Array?  I'm getting the same error as others mentioned in this post and have checked all the settings suggested with no such luck.  See error below:

filter array.PNG

dmistry
Level 8

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

@ovis2018  what is the value expression of apend array action? Please share screenshot

ovis2018
Level: Powered On

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

Hi @dmistry  - please see below.  "L3EtPOwner" is a people/group SP column, not allowing multiple selections, and "show field" is set to name (with presence).  "L3Owner" is a people/group SP column, not allowing multiple selections, and "show field" is set to email.  I did try using "Email" as the appendage in an earlier test run and got the same error messages as previously posted. 

 

Thanks! 

 

123.PNG

dmistry
Level 8

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

@ovis2018 , keep show field to "name with presence" and you need to change the formula, your formula is wrong.

 

first(item()?['LE3towner'])?['Email'], that should work.

ovis2018
Level: Powered On

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

@dmistry  - wish that worked but still receiving the "looking for array" error - see below.

 

Used the entry: 

Spoiler
first(item()?['L3EtPOwner'])?['Email']

1234.PNG

dmistry
Level 8

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

I think, I had the same issue where I had to delete the formula and re-add it again, make sure your AssignedTo column has users added, please share updated screenshot of the formula you have entered and list view as well if possible.

ovis2018
Level: Powered On

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

Thanks. I tried deleting the action, readding, and inputting the formula mentioned earlier and received the error below.  One item of note...I'm not using a SP tasklist but a regular SP list.  With that, I don't have an "assigned to" column but am referencing a people/group column added to a regular list.  Does that make a difference in how the formula should be setup?  

12345.PNG123456.PNG

ovis2018
Level: Powered On

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

@dmistry  --update --

 

I recreated the flow and am seeing some positive changes in the errors I'm now receiving...the value is the first letter of the first name of the individual listed in "L3EtPOwner".  Any thoughts to the changes necessary to the expression with this new finding?

Current expression for the Append to array variable --> 

first(item()?['L3EtPOwner']?['Email'])

new array error.PNG

 

ovis2018
Level: Powered On

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

@dmistry  okay...getting further along the workflow, but still erroring with the array. I'm getting successful tests through the Do Until, Get Items 2, and on Filter Array (within the Do Until) I'm getting an InvalidTemplate error - see below:

new error.PNG

ovis2018
Level: Powered On

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

Hi @Codered  - were you ever able to figure out the fix to the "Append to Array" error? 

Thanks!

ABHIS108
Level: Powered On

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

I am not able to understand the algo behind the approach suggested . Can someone explain what first() and union() is used for here

dmistry
Level 8

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

@ABHIS108  First() returns the first element in the array or string passed in.

Union (): Returns a single array or object with all the objects that are either in the array or object passed to this function.

dmistry
Level 8

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

@ovis2018 I hope you can forgive me for replying on this so late, so sorry.

 

Actually I ran into exact same issue when I was deploying flow in production and same error was showing up. 

In my case the people picker column allows People and Groups. Once flow failed in production I went into check config for Dev environment's people picker settings. All i had to is, allow multiple selections for the people picker column and the flow then works. 

 

So it seems flow won't read first index of the element if people picker column is not set to allow multiple selections.

Highlighted
DanFFSLA
Level: Powered On

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

@dmistry 

This is a great post - thank you for very detailed instructions. 

 

I've followed them and it works GREAT.

EXCEPT - While each email contains just a list of items assigned to the email adressee, each email is sent the number of times that matches the number of items in the list. For example, if a user has 3 items assigned to them, they receive 3 (identical) emails that each contains a listing of the 3 items. Another user that has 1 item only receives one email with his assigned item. 

 

Did i miss something obvious?

 

dmistry
Level 8

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

@DanFFSLA  Please share the screenshots of your flow with an expanded view of each action, might be the positioning of send an email action needs to be updated or the skip expression afterwords.

 

DanFFSLA
Level: Powered On

Re: microsoft flow get all items with distinct Assigned to (User and group) filed

I first tried the flow on my existing list and it was sending out multiple emails, just like I described. Then I specifically set up a task list just like in the example provided and made sure to follow the example verbatim. Still the same thing: flow works but sends multiple emails to each recipient. But at least each email contains a full list of items assigned to that recipient, which is pretty great in itself. 

I appreciate any and all help. 

 

Here are screenshots of my flow:

1.JPG2.JPG3.JPG4.JPG

Helpful resources

Announcements
firstImage

Microsoft Business Applications Virtual Launch Event

Watch the event on demand for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 Release Wave 2 Plan

Power Platform 2019 Release Wave 2 Plan

Features releasing from October 2019 through March 2020.

thirdimage

Flow Community User Group Member Badge

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

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Flow Community Video Gallery!

Users Online
Currently online: 395 members 4,491 guests
Please welcome our newest community members: