In AX 2012, we cannot use the set based operation on Dynamic queries (where filters on the query can be specified at run time). Now with AX 2012 R3, Microsoft has added a functionality to perform set based operation on Dynamic queries by adding a static method insert_recordset in Query class. More details can be found in the following blog post:


This is really helpful in improving SSRS report performance where Dynamic queries are used. Instead of using old code while (queryrun.next()), you should use this new set based method.

Enjoy Daxing.