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

GroupBy Displayname in Gallery

Hi All,

 

Im trying to Create an A gallery that will display some Data pulled from a Sharepoint list. I want the data to be grouped by the DisplayName of a persons Field in that list but it doesnt seem to work.

Im using the following formula:

GroupBy(MySharepointList,"MyUserField.Displayname","GroupByUsersDisplayName")

The grouping works properly when i use a simple text field from that same list.

 

Also is this possible to do it using a table in Powerapps or Gallery is the only way?

 

Thanks in advance!

 

1 ACCEPTED SOLUTION

Accepted Solutions
Power Apps Staff lesaltzm
Power Apps Staff

Re: GroupBy Displayname in Gallery

Hi there!

Unfortunately we don't currently support nested relationships in GroupBy, i.e "Myuserfield.DisplayName".

To make this work, you need to add the field you want to groupby as it's own column.

Try:

GroupBy(AddColumns(MySharepointList, "UserDisplayName", MyUserField.DisplayName), "UserDisplayName", "GroupByUsersDisplayName")

 

Let me know if this works for you!

 

lesaltzm

View solution in original post

4 REPLIES 4
gchris7
Level: Powered On

Re: GroupBy Displayname in Gallery

Anyone knows how this can be done?

Power Apps Staff lesaltzm
Power Apps Staff

Re: GroupBy Displayname in Gallery

Hi there!

Unfortunately we don't currently support nested relationships in GroupBy, i.e "Myuserfield.DisplayName".

To make this work, you need to add the field you want to groupby as it's own column.

Try:

GroupBy(AddColumns(MySharepointList, "UserDisplayName", MyUserField.DisplayName), "UserDisplayName", "GroupByUsersDisplayName")

 

Let me know if this works for you!

 

lesaltzm

View solution in original post

gchris7
Level: Powered On

Re: GroupBy Displayname in Gallery

Thank you lesaltzm. It worked great!

 

Now im trying to add the jobtitle of these users but im getting errors again. I tried the bellow but nothing worked.

 

GroupByUsersDisplayName.MyUserField.JobTitle

GroupByUsersDisplayName.UserDisplayName.JobTitle

AddColumns(GroupByUsersDisplayName, "JobTitle", MyUserField.JobTitle)

 

Any ideas?

gchris7
Level: Powered On

Re: GroupBy Displayname in Gallery

Bumping this, incase someonw knows a solution for my second question

Helpful resources

Announcements
thirdimage

Power Apps Community User Group Member Badge

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

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

SecondImage

Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

Top Kudoed Authors (Last 30 Days)
Users online (4,015)