Partial Records #74
Replies: 3 comments 3 replies
-
There is definitely something to say about this, absolutely. What are you thinking of exactly, @kine ? I'd refer to docs for the syntax and HOW to use it. I'm thinking of: Don't use when you intend to modify the record but what else? 🤔 |
Beta Was this translation helpful? Give feedback.
-
How to use it e.g. when passing the rec as parameter (by ref) to another function (which I have under control or I do not have under control) and how to work if I am consuming record as parameter from outside (and I am in control of the call or I am not) |
Beta Was this translation helpful? Give feedback.
-
Correction - it seems that modifying a record is perfectly possible in combination with partial records. It seems that this: procedure SetLoadFieldsAndModifyDifferentField()
var
JustSomeTableWLD: Record "Just Some Table WLD";
begin
SelectLatestVersion();
JustSomeTableWLD.SetLoadFields(Message);
JustSomeTableWLD.LockTable();
JustSomeTableWLD.FindFirst();
JustSomeTableWLD."Message 2" := Format(Random(1000));
JustSomeTableWLD.Modify();
end; results into a simple partial SELECT and one UPDATE, and that's it. It seems there is some tracking behind the scenes where the client knows which fields were modified .. ? @KennieNP , @JesperSchulz , could you confirm? |
Beta Was this translation helpful? Give feedback.
-
How to use correctly, when own local variable, when parameter from outside...
Beta Was this translation helpful? Give feedback.
All reactions