原文地址:http://axdaily.blogspot.com/2010/01/insertrecordset-and-entirecache.html
It is known fact that set-based operations, like insert_recordset, update_recodset and delete_from are falling into row-by-row operations under certain circumstances. For example, if table has insert (update or delete) methods overridden or table has delete actions or aosValidate methods are overridden. To avoid such fallback (of course, if it is acceptable that mentioned logic won’t be executed) several methods should be called to disable each of the mentioned cases, for example:
inventItemGroup.skipDataMethods(true);
inventItemGroup.skipDeleteActions(true);
inventItemGroup.skipAosValidation(true);
However, if a table’s CacheLookup property is EntireTable and insert method is overridden, insert_recordset operation (and only it) will fall into row-by-row operations despite the mentioned calls. To avoid that cache should be disable too, like:
inventItemGroup.disableCache(true);
转载请注明:ww12345678 的部落格 | AX Helper » [转]Microsoft Dynamics AX Insert_recordset and EntireCache