Hi all,
I have applied a group by and sum of in a form, modifying its data source execute query method.
maYearlySummaryDatasource.addGroupByField(fieldNum(maYearlyAffiliateTable,groupId));
maYearlySummaryDatasource.addSelectionField(fieldNum(maYearlyAffiliateTable,AmountCur),SelectionField::Sum);
based on a checkbox selection this group by and sum should be applied. I have written logic for that.
I want to clear the group by and sum of on unticking the check box.
I was able to clear the group by with
this.query().clearGroupBy();
but unable to clear the (sum of) with
this.query().clearHavingFilters(maYearlySummaryDatasource,fieldStr(maYearlyAffiliateTable,AmountCur));
Kindly suggest how to achieve this.
Thanks,
Praveen.
How to clear selection field with sum in a query in x++
*This post is locked for comments