I run FM 11.
I use onObjectSave to write an entry to a log table of the form
but I don't know how to capture OldValue.
The approach which ought to work is to use a separate onObjectEnter trigger to write the current value of the selected field to a global field. But onObjectEnter does not fire when one selects a field within a portal (it fires only when a different portal row is selected).
I could use onRecordLoad to copy the entire record to mirror table consisting of globals, and get OldValue from this mirror table whenever the user changes the corresponding field in the real table. But I'm dealing with a table with hundreds of columns. Seems like too much work.
The number of columns also makes UltraLog infeasible. The list of fields in the calculation UltraLog( LogData; ModStamp; "TheText¶TheText¶TheNumber¶TheDate¶TheTime") would be the length of a short story -- much too tricky to maintain.
What I need is either a beforeModify trigger, or the DELETED and INSERTED tables provided by Transact-SQL (but I don't want to use ESS in this case).
What's the efficient FM way to do this?