This is a migrated thread and some comments may be shown as answers.

virtual scrolling and grouping

11 Answers 382 Views
Grid
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Tom
Top achievements
Rank 1
Tom asked on 14 Sep 2011, 02:53 PM
I've noticed that having virtual scrolling and grouping enabled at the same time causes the following issues:

  • If grid has not been scrolled yet and you choose to group on a column: grouping seems to be working OK but afterwards scrolling causes incorrect rows to appear in the grid. Taking grouping off causes all rows to disappear.
  • if grid has been already scrolled and you choose to group on a column: all rows will disappear
  • Once rows are gone, the grid is broken permanently and full page reload is required to make it work again.

01.$("#grid").kendoGrid({                     
02.    dataSource: {
03.        data: jsondata,
04.        pageSize: 10
05.    },
06.     scrollable: {
07.         virtual: true
08.     },
09.     groupable: true,
10.    columns: ["id", "col1", "col2", "col3", "col4", "col5"]
11.});

We're using "local" data source of 10'000 rows of JSON in following format:

[
{"id":1,"col1":"O2TnVBjrO","col2":"PGBj8mj4","col3":"T7omqdd","col4":"Hy5FVOzFL","col5":"oetLhPoD8JV0"},
{"id":2,"col1":"MLCkBeX2Ly","col2":"u9v7Mcp5gz","col3":"Wg0vP","col4":"FjUWTyDZFr2qNYu","col5":"9FzeaFf"},
...
]

Is this a known bug or we're doing something wrong with the configuration? Are these features meant to work together and if not is it something that you plan to support?

11 Answers, 1 is accepted

Sort by
0
Rosen
Telerik team
answered on 14 Sep 2011, 02:58 PM
Hi Tom,

I'm afraid that currently having both grouping and virtual scrolling enabled is not supported. We will do our best to include support for this in feature versions of the component.

Best wishes,
Rosen
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
haridas
Top achievements
Rank 1
answered on 06 Nov 2012, 02:44 PM
We are using the Q2 2012 SP1 (version 2012.2.913) - September 2012 service pack of Kendo UI complete for UI ASP.NET MVC . Seems the issue is reproducible with this build as well. Any updates on the bug fix ?

0
vikas
Top achievements
Rank 1
answered on 22 Jan 2013, 10:29 AM
Hi I used Grouping and Virtual Scrolling together in v2012.2.710 successfully in ASP.net MVC, but in current version v2012.3.1114 it seems not working, it gives error message "Grouping and Virtual Scrolling is not supported.".

can you please confirm if this is true, if yes please give me some workaound how to enable this.
0
VP
Top achievements
Rank 1
answered on 24 Feb 2015, 04:25 PM

Hello

I have a page in which I return about 500+ records and the Grid takes about 15 secs to load. Everything up-to the point where I get data from the DB is really fast (less than a sec), but when the data is returned from the controller "Json(vm.ToDataSourceResult(request))" to the time it takes to render the data is really slow. The grid uses Ajax Binding and has default Grouping by 3 columns, and some sorting (See GridDefaults.PNG). To overcome the slowness I tried using Virtual Scrolling, but this correctly loads the grouped data for the first loaded page (say 100 records) (See Capture.PNG) but on scrolling, the rest of the pages does not have the sub data (See Capture1.PNG). 

Why is the rending this slow?
Is virtual scrolling supported with Grouping? 

Thanks.

0
Rosen
Telerik team
answered on 27 Feb 2015, 08:26 AM
Hi VP,

Indeed, as of Q1 2013 release having virtual scrolling and grouping is possible.

Unfortunately, the provided information is not sufficient in order to tell what may be the cause for the behavior you have described. Therefore, you should open a separate support request (as it is not related to the current thread topic) and provide a small runnable sample in which the behavior you have described can be observed locally.

Regards,
Rosen
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
VP
Top achievements
Rank 1
answered on 06 Mar 2015, 08:02 PM
Hi Rosen

Thanks for the info. I have opened a separate request for the other issue.

As you have stated that starting Q1 2013, Kendo Grid does support virtual scrolling and grouping, but for my code, it actually works in the first load and breaks after we scroll for some records not showing the sub-data inside the parent group.  Can you please point me to a sample where I can compare with a working example where this works. This should be with atleast 3 levels of grouping and virtual scrolling.

.Group(groups =>
           {
               groups.Add(p => p.Column1);
               groups.Add(p => p.Column2);
               groups.AddDescending(p => p.Column3);
           })
.Sort(s =>
           {
               s.Add(c => c.Column4).Descending();
           })



Thanks,

VP
0
Rosen
Telerik team
answered on 09 Mar 2015, 03:14 PM
Hello VP,

We were able to observe the empty group header issue locally and to address it. The fix should be available with the next internal build.

However, you should be aware that there are some limitations when using grouping and Grid virtualization, related to the variable row size which may result in some unexpected behavior in certain scenarios.

Regards,
Rosen
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
VP
Top achievements
Rank 1
answered on 13 Mar 2015, 06:46 PM
Hi Rosen

Would you have an approximation on when this fix should be available for me to update.

Thanks
0
Rosen
Telerik team
answered on 17 Mar 2015, 11:57 AM
Hello VP,

This fix should be already available in the current internal build. You should download it from your account and give it a try.

Regards,
Rosen
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
Bridge24
Top achievements
Rank 1
Iron
answered on 06 May 2015, 06:08 PM

Hi... is the virtual scrolling + paging supposed to work or not?  We tried a little bit and we get a lot of strange issues.

I provide you 3 screenshots:

To build these 3 screenshots, I load my data, and after, I drag the "assigned" column to the group-by section.

1. The whole data set without paging and scrolling - the group headers is OK, and I see all my groups.  The total of the headers is the total of my dataset count, 359, and I have 7 groups. 

2. If scrolling-paging is enable, I only get 3 groups (because on the first page, these are the groups I can see).  But, for the last item, you read the full dataset, and get the good count.  But, not the other groups.

3. After scrolling down sample 2, until I reach the "invisible" page 2, when I get back to top, now I always have these 3 headers, but the third one is not with count "30" instead of 332, being the number of items for that group I get in page 1.

Also, when I scroll with all headers "closed", when I reach the "invisible" page 2, all my <tr> suddenly appears, I must get back to top to re-close the group headers.  I think that, when everything is closed, I may not be able to scroll, because I see no data.

So, my question... is it possible, using virtual scrolling + paging, to get the whole group header correctly set, from the "original" data source without pages, even if I want to use scrolling to make my big dataset display faster.

I think that, for now, the kendo grid is, in fact, incompatible with virtual scrolling + paging at the same time.

 

 

0
Rosen
Telerik team
answered on 07 May 2015, 03:09 PM

Hello Dani,

As you have noticed, the virtualization when grouping is enabled works the same way as if the paging is used - there will be no additional items shown when groups for the current page are collapsed. The opposite behavior will require totally different than the current paging algorithm, which is currently not possible to be incorporated in the DataSource.

Regarding the count value. Could you please verify that you are not using in-memory aggregates calculations with server-side paging. This will yield incorrect results as the calculation will be executed only over the available data. It is advisable to use either only server operations or in-memory operations.

As this thread is a bit old and the discussion has diverge from its initial message I would ask you to open a separate support request if additional questions arise.

Regards,
Rosen
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
Grid
Asked by
Tom
Top achievements
Rank 1
Answers by
Rosen
Telerik team
haridas
Top achievements
Rank 1
vikas
Top achievements
Rank 1
VP
Top achievements
Rank 1
Bridge24
Top achievements
Rank 1
Iron
Share this question
or