Won't Fix
Last Updated: 09 Feb 2021 16:16 by Orce
Orce
Created on: 08 Feb 2021 15:50
Category: UI for Blazor
Type: Bug Report
0
Grid does not show all of the items properly when Skip + Page Size > Total Count

Hi Telerik team,

in our Blazor App we have implemented the skip handling logic according to your documentation, but we have noticed an issue. When the sum of the skip and the page size is bigger then the total count of the items and we try to set the Skip property for the second time, some of the top items are not shown.

To demonstrate this, we have created a simple app: https://github.com/0rce/blazor-app-telerik-grid-skip-bug.git

Please clone the repo, start the application and follow the steps displayed above the grid to reproduce the bug.

Do you think it is a bug or is our implementation wrong?

Best regards,

Orce

---

ADMIN EDIT

I have linked this case in the Limitations section of the documentation and you can find more details and a path forward in this KB article: https://docs.telerik.com/blazor-ui/knowledge-base/grid-large-skip-breaks-virtualization.

Considering this and why the grid cannot and should not change this value for you, I am marking this with the "Won't Fix" status - I acknowledge it is behavior that is less than ideal, yet it stems from application logic and the grid cannot fix that.

If someone is looking at the provided repository - please also be aware that it showcases an invalid approach for fetching grid data that I strongly advise against. Review the rest of the thread for more details.

---

4 comments
Orce
Posted on: 09 Feb 2021 16:16

Hi Marin,

thank you for your prompt replies.

I think I'll be able to incorporate the solutions for both a skip value to large and not enough data to fill the whole page size.

Best regards,

Orce

ADMIN
Marin Bratanov
Posted on: 09 Feb 2021 11:27

Hi,

I have linked this case in the Limitations section of the documentation and you can find more details and a path forward in this KB article: https://docs.telerik.com/blazor-ui/knowledge-base/grid-large-skip-breaks-virtualization.

Considering this and why the grid cannot and should not change this value for you, I am marking this with the "Won't Fix" status - I acknowledge it is behavior that is less than ideal, yet it stems from application logic and the grid cannot fix that.

Regards,
Marin Bratanov
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

ADMIN
Marin Bratanov
Posted on: 08 Feb 2021 17:10

Hi again Orce,

Even though the provided scenario is not valid and what I said in my previous post is true, I did test a valid configuration and, indeed, setting a skip so that there aren't enough data items for it can show the placeholders. Thus, I am reopening this so we can review it in more detail and I am attaching here the sample page with the valid scenario so you can also compare against it.

Regards,
Marin Bratanov
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Attached Files:
ADMIN
Marin Bratanov
Posted on: 08 Feb 2021 16:40

Hi Orce,

This is a limitation of the virtual scrolling feature - it requires that there are more items in the data than the page size, you can read more about it and find a workaround in the Limitations section of the feature: https://docs.telerik.com/blazor-ui/components/grid/virtual-scrolling#limitations.

I also advise that you review the same question and issue posted by your colleagues last May: https://feedback.telerik.com/blazor/1466279-grid-does-not-set-skip-correctly-when-fetching-data-from-a-web-api. What is most important is that this is not the correct way to use virtualization and to optimize the data queries - you should tell the grid what the total amount of records is and return only the current page of them instead of all of them. This lets you do server filtering and paging too, instead of hacking it on the client. Since the project is also the same (even if forked under a new repo), I am assuming you still have not updated to this approach and I strongly advise that you review the concept explained in the sample project I linked: https://github.com/telerik/blazor-ui/tree/master/grid/datasourcerequest-on-server.

Regards,
Marin Bratanov
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.