Come posso ottenere il numero di giorni che intercorrono tra la data più remota delle registrazioni
e la data odierna???
Grazie a chi vorrà aiutarmi.
If you have a list of dates - then maybe use GetAsNumber on each date to convert it to a number then you could do something like this. And using the new SortValues function in FM 16. Once converted to a number then you can do the same with the current date and you'll have your number of days since the oldest date in your list.
GetAsNumber ( Get ( CurrentDate ) ) - GetValue ( SortValues ( List ( DATES::converted ) ; 2 ; "English" ) ; 1 )
You can find our more about that SortValues function in FM 16 help
FileMaker Pro 16 Help
Hope this answers your question.
Another follow up to this and it avoids having to add another field to your schema, however you have to use another function. Here is the resultant calculation.
Get ( CurrentDate ) - GetAsDate ( GetValue ( SortValues ( List ( DATES::Date ) ; 3 ; "English" ) ; 1 ) )
Using the SortValues function you can just sort by date in ascending order. Then make sure the first value is then converted to a valid date.
Retrieving data ...