Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Friends,
Need help to get Difference between now() and another date field to create ageing in minutes and hours.
In below example am getting ageing in Days. in same way need to get ageing in minutes and Hours
IF(Num((Date(today(),'DD/MM/YYYY h:mm:ss TT') - Date(Open_DateTime,'DD/MM/YYYY h:mm:ss TT'))) <=1,'>1 Day',
IF(Num((Date(today(),'DD/MM/YYYY h:mm:ss TT') - Date(Open_DateTime,'DD/MM/YYYY h:mm:ss TT')))>1 AND
Num((Date(today(),'DD/MM/YYYY h:mm:ss TT') - Date(Open_DateTime,'DD/MM/YYYY h:mm:ss TT'))<=3),'<3 Days',
Instead of today() am using Now().
Please help me regarding this.
Thanks in Advance...
Vinay N
Try a simpler one, like:
Class( today()-Open_DateTime, 1, 'day')
Hi Tresesco,
Thanks for the Reply. Exactly my requirement is...I want to find out the total number of tickets violating in next 30 mins, 1 hour, 2 hour and 4 Hour. So I need to consider Now() function. So I need to get Minutes and Hours also with Days. so please suggest
Try like:
floor(now()-Open_DateTime) - No of days
hour(now()-Open_DateTime) - hours
minute(now()-Open_DateTime) - minutes
second(now()-Open_DateTime) - seconds
The interval() function will return the difference between two datetime values.