Following code illustrates how we can use SysQuery::countTotal() method to get the number of records in Query. static void Query_cntRecords(Args _args) { Query query = new Query(); QueryRun queryRun; QueryBuildDataSource qbd; ; qbd = query.addDataSource(tablenum(CustTable)); queryRun = new QueryRun(query); info(strfmt("Total Records in Query %1",SysQuery::countTotal(queryRun))); } Microsoft Dynamics…
Tag: QueryRun
Microsoft Dynamics Ax
Axapta queries Fact
by Bo Jensen •
The query object model contains classes to define and run a query. These objects are used to define the query data source, the fields returned, record ranges and relations to child data sources. The following illustration shows the object model. DAX Blog: Axapta queries Fact