How to calculate the difference between to attributes of type date and time?

0
Hi all, I have an entity with the following attributes:   Begin  8/15/2020, 1:47 PM End     8/15/2020, 5:44 PM Difference I would like to calculate the difference between End and Begin and store it in the attribute Difference in minutes. Can anybody tell me, how to do that? Thank you!
asked
4 answers
3

Hi Siegfried,

As Tim suggested, minutesBetween is the solution for your requirement.I am sharing other documentation which explains different functionality that can be achieved using datefuntions.

https://docs.mendix.com/refguide/between-date-function-calls

https://docs.mendix.com/refguide/add-date-function-calls

answered
2

Use the function minutesBetween:

And add that microflow named ‘Calc_Difference’ as the calculation-microflow of the attribute ‘Difference’:

answered
0

Perfect solution! Tanks a lot!

answered
0

Perfect solution. Thanks very much!!

answered