If you only want to show the date, why not use a date field that auto-enters the modification date in the first place?
In the customer table, you could define this calculation that returns the most recent modification date from your timestamp fields (do not use text fields here)
Max ( GetAsDate ( _ModifDate ) ; GetAsDate ( Last ( Invoices::_ModifDate ) ) )
Select Date as your return type
Thanks for the suggestion but it does not seem to take into account when changes are made in the Invoices table. Am I correct that I should configure this not as a calculation but as a date field using auto-enter calculation?
In fact, I am using Timestamp in the individual tables and Date for the max because for the moment, I just need to know the latets modification on day level but I might need it on a timestamp level later. Therefore, I prefer to already have the timestamps stored as from now.
This should not be a date field with an auto-entered calculation as changes in the related table cannot trigger the needed update. This should be a field of type calculation.
I have tried to use a calculation field the result stays the same. This is what I have as formula for TableA::_ModifDate_Latest:
Max ( GetAsTimestamp (_ModifDate_TableA ) ; GetAsTimestamp ( Last ( TableB::_ModifDate_TableB ) ) )
When I make a change in Table A, _ModifDate_Latest = _ModifDate_TableA but if afterwards I make a change in Table B afterwards, _ModifDate_TableB gets updated but _ModifDate_Latest remains the same (=_ModifDate_TableA).
Any idea what I am missing here?
Ok, that last function is the issue. The relationship for your related table needs to specify that the related records be sorted by the modification timestamp field in ascending order so that the most recently modified record will be the last related record.
You could also specify a descending sort order and remove the last function from the calculation.
To specify a sorted relationship, double click the relationship line to open the Edit Relationship dialog and then click the Sort button for the related table's side of the relationship.
Worked like a charm!