Wednesday, January 18, 2023

Difference between insert method and RecordInsertList X++

 RecordInsertList is a class, not a method. You can learn more about it in documentation:

I believe CAR looks for inserts inside loops, with the assumption that instead of calling database every time (e.g. 100 executions => 100 database calls), you could put records into a RecordInsertList and insert all records in a single DB statement.

If your loop execute just once, but then you should get rid of the loop.

Maybe you can't use RecordInsertList with your current code, but then maybe you should redesign your solution.

But of course, the tool is quite simply and you may have a legitimate reason to violate this rule, although I can't currently think of any. Show us your code if in doubt.

CAR(Customization Analysis Report)

No comments:

Post a Comment

My Requirement is Delete option in Vendor Master for all roles except System Administrator

   [FormControlEventHandler(formControlStr(VendParameters, VendParameters_YNV_VendorMasterDeletionOption), FormControlEventType::Modified)] ...