cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
mp6
Helper I
Helper I

Properly set delegation formula not delegating

I haven't seen any posts with similar issues...

I have a completely delegable function:

ClearCollect(RouteInfo7,Filter('HB Orders',DateID=SelectedRoute));
'HB Orders' is a SharePoint list, and  the DateID field and SelectedRoute are both numbers.
 
However, the function is not delegating! I know this for a fact because I changed the non-delegation collection limit to 1, and it only loaded one row. Its causing the app to be extremely slow to start.

Any suggestions or clues why this would be the case?
27 REPLIES 27
mp6
Helper I
Helper I

Also, when I put my delegation limit back up, it still doesn't collect any rows that are above 500 from the complete table (before the filter) 

If its the collection that's the issue, and not the filter, why does the filter not look past row 500?

@mp6 ,

Even a non-delegable query will return 500 records in a second, but I have to ask again, why are you loading this at App OnStart when the Variable SelectedRoute would be Blank at that point?

@mp6 ,

A collection will only collect records up to your Delegation limit (max 2,000)

@WarrenBelz I tried this using your With function..still only loading 3 (my current limit) 😕

 

It's not loading OnStart its loading OnSelect... did I say something that made you think otherwise?

@mp6 ,

You need to set your Delegation limit as high as you need for the collection numbers you want. Go back to the code I posted - you can put a Delegable filter as the basis for a collection on any sized list and as long as the returned filtered records are less than your Delegation limit, it will collect them. There will be other opinions on this, but all my apps are set to 2,000.

mp6
Helper I
Helper I

Got it. So I moved by limit back up. Now how do I test if its delegating?

@mp6 ,

It is . . . . but you are making a collection, which is not.

If you really want to confirm that two numeric values are Delegable, go back to the start on your Gallery

Set(SelectedRoute,ThisItem.DateID)

then put this in another gallery

Filter(
   'HB Orders',
   DateID=SelectedRoute
)

set your limit to 1 and see how many rows you get in your gallery. Also you might have a read of this blog on mine on Delegation. I assume you are not now running this at App OnStart?

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Visit my blog Practical Power Apps

 

Helpful resources

Announcements
Power Platform Call June 2022 768x460.png

Power Platform Community Call

Join us for the next call on August 17, 2022 at 8am PDT.

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Users online (1,578)