Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I want to write a expression in which i need to subtract the two dates field and i need to convert the result field in to hours, days and minutes. I am looking for the syntax to follow and little confused with the functions to use,
Any help will be highly appreciated,
Thanks,
Praveen.
Hi,
Use interval function
interval(MaxDate-MinDate,'D hh:mm')
Hope it helps
Celambarasan
Celambarasan is already answered it...
FYI for getting the data in hours... change the format to interval(EndDate-StartDate,'hh:mm:ss')
Hi,
Use Interval(), for getting the difference
Ex:
Interval(StartDate - EndDate, 'D hh:mm')
Regards,
Jagan.
Hi,
I am not getting correct results, by default in the output it throws the date columns and it shows hours and seconds. I want to display only hours and seconds and most importantly i need to sum it.
For eg i need to sum(hours) and sum(minutes) and display it one row.
Any help towards this,
Hi
Try this
num#(intervalmatch(Date1 - Date2,'d'),'##') as Day
num#(intervalmatch(Date1 - Date2,'hh'),'##') as Hour
Now you can sum them
Regards,
Kaushik Solanki
still am not getting the correct answer, the above syntax doesnot works. I need to remove match in that, only then it works.
Hi,
Oh yes its my typing mistake, apologies for that.
Are you getting correct answer when you use Interval in above expression?
Regards,
Kaushik Solanki
still i am not getting, one of the columns used in interval function also throws in output, i need only the hrs and minutes,
Any help??
Hi,
Can you please tel me about your problem in brief ?
Celambarasan