Hi all,
Is anyone able to explain how OData filtering is working along with the Pagination in SharePoint 'Get items' action?
I have the list that contains 10k records and My flow is triggered when new item is created.
I need to get only records where Title equals 1. Record's ID are as per the below screenshot.
Once i run the flow with OData defined to Title eq '1' and disabled pagination, i receive 2 items with ID 1 and 10:
OK, i get it. By default, items threshold is set to 100 first items once Pagination is disabled:
But if i enable pagination with threshold set to 100, and defined filter query, i'm receiving 4 items(as if whole 10k records would be taken for filtering).
When i removed Filter Query from the action, i received 100 records as expected 😕
Could anyone explain how query to the SharePoint is executed in these instances?
it looks as if with disabled pagination, firstly 100 items are extracted, then filtering is performed on this 100 records and finally items are sent to the flow, once with enabled Pagination, firstly entire table is filtered and then items are sent to the flow.
Hi @v-qiaqi-msft,
Thank you for your answer 👍.
What about if pagination is disabled, and filter query is set to Title eq '1' as per the below screenshots?
According to your explanation, it should capture all the records that fit the query (4 records), and return them since 100 records threshold is not exceeded.
But actually I'm receiving 2 items
Hi @Lemak89,
I think I get what you want.
I want to explain to you that the Get Items action will always capture all the records that fits the filter query but return only 100 of them at max.
For example, you have 200 records that Title equals 1, but the final result will always return 100 of them if you set the threshold as 100 no matter you enable the Pagination or not.
In your scenario, you enable the Pagination and you set the threshold as 100, the filter query helps you capture all the records that fits the condition, so it displays 4 as result.
However, if you remove the filter query and keep other settings same, it will always display 100 as result for that you have set the threshold as 100.
WarrenBelz
146,596
Most Valuable Professional
RandyHayes
76,287
Super User 2024 Season 1
Pstork1
65,928
Most Valuable Professional