Displaying group count in aggrid

Forum to discuss the new web client version of Servoy.

Displaying group count in aggrid

Postby jay.rao » Fri Jun 22, 2018 11:43 am

I am trying to customise the AGGRID for the test. I want to display the child counts on grouping the column.For e.g, if I have grouped the column Status I want to see the total count of child records in each Status group, ACTIVE(21), CLOSED(5) etc.
As we have groupingtable_server.js where we get groupedfoundset, I want to get the count for each group as well in the foundset.

Code: Select all
var childFoundset = parentFoundset.duplicateFoundSet();
var query = parentFoundset.getQuery();
groupColumn = query.getColumn(groupDataprovider);
var pkColumns = query.result.getColumns();
for (var i = 0; i < pkColumns.length; i++) {

But when we add the count to the query result it throws the warning
"The query does not have the correct number of pks in the select"

Do you have any suggestions on what am I doing wrong here?
Posts: 59
Joined: Mon Apr 10, 2017 1:32 pm

Return to Servoy NGClient

Who is online

Users browsing this forum: No registered users and 1 guest