Hi. I have a somewhat convoluted problem with enabling grouping, and I've had great difficulty reproducing this in a small sample app, but that app does have some issues so I'm hoping some insight into these issues might also help in my actual application.
I have a grid, and the exact format (number of columns, names/titles/data types/display format of those columns, which columns are "Frozen", etc) is NOT KNOWN at compile time. I have managed to get the grid to work by using an object derived from `DynamicObject` as the Row type, and the "Fields" are named based on indexing so if a table column is defined as field `__F0` or similar then that is Addressed via `TryGetMember` which works out which of an array of fields is being pointed to.
The Header of each column is calculated at runtime and injected in using the `<HeaderTemplate>` property of the Grid Column, as this can include line breaks and other bits of information.
We re-use this approach in more than one place, and because we sometimes have hundreds of rows I've found that using virtualisation helps a lot.
I have managed to get the grid to work fine, and display Totals as well, but when I try to use grouping I've found it just doesn't show any data rows at all when I'm using virtualization, and if I turn that off there's some other strange behaviour:
If my grid looks like this:And I then group by the first column, I see the following issues:
Hi Giles ,
Thanks for contacting Syncfusion support.
We have analyzed your query, we suspect that column with one to many relationship. currently we don’t have support to perform DataOperations in a column with one to many relationship data (like List<object>) in Grid column. We have considered to implement this feature “Provide data operation for one to many relationship columns” request, and added this to our feature request list. Based on specific parameters including product vision and technological feasibility we will implement this feature. This feature will be available in any of our upcoming releases. In the meantime, we suggest you to use our Complex column and foreign key column features which can be used to display values from different tables that have the same foreign key. Please refer to the attached documentation for more information
Reference: https://blazor.syncfusion.com/documentation/datagrid/column-rendering#complex-data-generation
https://blazor.syncfusion.com/documentation/datagrid/foreignkey-column
Feedback Link : https://www.syncfusion.com/feedback/12731/provide-data-operation-for-one-to-many-relationship-columns
Please let us know if you have any concerns.
Regards,
Naveen Palanivel
Hi. I'm not sure what you mean by a one-to-many relationship; There is nothing I would regard as such in this scenario. Each column is pointing to a single value, albeit one fetched from an object via a "property Name" which is resolved at runtime via use of a DynamicObject. The object representing a *row* contains a list of items, and each item in the list represents a single cell.
There is no "lookup" of data required beyond simple functions which get things like headers and cell formats, and none of my questions relate directly to those functions. For clarity my actual questions are:
Hi Giles,
Sorry for the inconvenience caused.
Upon reviewing your query and the shared code snippet, it appears that you are
attempting to perform a grouping operation within the frozen columns.
Unfortunately, this functionality is not feasible to achieve as frozen rows and
columns do not support this feature. We have previously mentioned this
limitation in our UG documentation. Kindly refer the attached documentation
link for more reference.
Reference: https://blazor.syncfusion.com/documentation/datagrid/scrolling#limitations
If you have any further queries, please get back to us.
Regards,
Sarvesh