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

Delegation warning on SharePoint list lookup column .Id versus .Value

I'm having an issue with delegation and, after having read all of the documentation, I have yet to see a description of the exact issue that I'm seeing. I know that the PowerApps filter function can be delegated to SharePoint for SharePoint lookup columns, but it seems that this functionality is limited to when you use the ColumnName.Value and not the ColumnName.Id. Let me describe a simple example. 

 

There are two lists, Projects and Project Statuses. The Project Statuses list has a lookup column named Project, and it looks up to the Title column of the Projects list.

 projects list.pngProjects listproject statuses list.pngProject Statuses list

In this example, I want to have PowerApp that filters the Project Statuses based on the selection from the Projects list, thus using a gallery Filter to show the items from Project Statuses. 

 

As described above, I have no problems if I do a filter like this using the Value attribute of the lookup column:

Filter('Project Statuses', Project.Value = "Project MNO")

filter by project dot value.pngFilter by Project.Value; no delegation warning

However, if I want to use the Project.Id this would then throw a delegation error. In the simple example that I'm using this is less of an issue if I just use the SharePoint settings to require a unique value for the title field, but this would not be a viable option if I had a list that couldn't enforce unique values on the column used in the lookup column. Here's the delegation error when I change to Project.Id: 

Filter('Project Statuses', Project.Id = 5)

filter by project dot id.pngDelegation warning with Project.Id

For the purposes of the solution that I'm managing, the 2000 item limit will probably be met fairly quickly, and requiring  unique values on the source list column is not an option. Does anyone have any ideas on how to work around this limit, or suggestions on what could be done differently? 

1 ACCEPTED SOLUTION

Accepted Solutions
Edwin-Abdalian
Level 10

Re: Delegation warning on SharePoint list lookup column .Id versus .Value

I wasted a day on this and I'm sure you did too. Yes, it only works on the Value, and not the sharepoint ID. but this is not what the documentation says, at least that was my understanding that I could use ID.

What you could do, when you create the lookup in SharePoint, set the value of the lookup field to ID, and then use the additional lookup fields to add the other columns like Name and descriptions into your listmyLookup.png

 

View solution in original post

4 REPLIES 4
Edwin-Abdalian
Level 10

Re: Delegation warning on SharePoint list lookup column .Id versus .Value

I wasted a day on this and I'm sure you did too. Yes, it only works on the Value, and not the sharepoint ID. but this is not what the documentation says, at least that was my understanding that I could use ID.

What you could do, when you create the lookup in SharePoint, set the value of the lookup field to ID, and then use the additional lookup fields to add the other columns like Name and descriptions into your listmyLookup.png

 

View solution in original post

bynumhoekstra
Level: Powered On

Re: Delegation warning on SharePoint list lookup column .Id versus .Value

Thank you very much for your response @Edwin-Abdalian! I did spend quite a long time researching options, but hadn't considered switching the ID on the SharePoint side. Do you know if making this change after the initial column creation would change the way that the column is referenced in PowerApps, or does this now make it possible to call ColumnName.Id without the delegation error? 

 

Edit - I just looked at your screenshot again saw that you're saying it should be Columname.Value. Going to test now!

Edwin-Abdalian
Level 10

Re: Delegation warning on SharePoint list lookup column .Id versus .Value

yes, please try it in you Dev environment. After applying these changes, your "Project" column in the Status list, will contain the ID of the projects, but now as a value, which you can use it in PowerApps without getting the delegation warning.

and as I explained in the picture, to display the project name in your list, you need to add the "Project Name" column to your lookup. you will have a new column called "Project:Project Name" in your list.

bynumhoekstra
Level: Powered On

Re: Delegation warning on SharePoint list lookup column .Id versus .Value

Yep, looks like it works! No more warning, though I did have to wrap the selected ID from the parent list in a Text() function so that it compared the values as strings.  The below screenshots are different data from when I initially made the demo, but no more delegation warning. Thanks again!

lookup switch id.pnglookup column change.pnglist view.png

Helpful resources

Announcements
thirdimage

Power Automate 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

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors (Last 30 Days)
Users online (6,579)