Question 590
A stock process should update only records in one location but loops through every warehouse item. The developer recommends the following change: Apply Record.SetRange or SetFilter before iterating the selected records. Which technical explanation most directly justifies it in this case?
Explanation
Correct Answer
AL record filters constrain which database rows the record variable will read and process. It connects the proposed action to the exact failure or requirement—A stock process should update only records in one location but loops through every warehouse item. Confirmation would be instrumented runs touch only the intended sales or stock records and leave other rows unchanged.
Incorrect Answers
That mechanism explains why the alternative action—iterate matching al records with findset and the appropriate next pattern—helps in another case. It does not justify the proposed fix here; al record filters constrain which database rows the record variable will read and process. The distinguishing requirement is: A stock process should update only records in one location but loops through every warehouse item.
That mechanism explains why the alternative action—use supported instream and outstream handling for file or blob content—helps in another case. It does not justify the proposed fix here; al record filters constrain which database rows the record variable will read and process. The distinguishing requirement is: A stock process should update only records in one location but loops through every warehouse item.
That mechanism explains why the alternative action—apply al access modifiers to restrict internal implementation members—helps in another case. It does not justify the proposed fix here; al record filters constrain which database rows the record variable will read and process. The distinguishing requirement is: A stock process should update only records in one location but loops through every warehouse item.





Microsoft Dynamics 365 Business Central Developer (MB-820) Practice Tests