Bojensen Blogs

Tag: RecordSet

Dynamics Ax – Update the records with single query statement.

For updating the ‘N’ no. of records we can use simple query statement instead of using while loop. (i.e. while select inventTrans where ) By using update_recordset we can update multiple records at a time. oldRFQCaseId = this.orig().RFQCaseId; ttsbegin; update_recordset inventTrans setting TransRefId = this.RFQCaseId where inventTrans.TransRefId == oldRFQCaseId; ttscommit; Dynamics Ax – Update the…