Using rel_date_diff() as an expression or in any of the calculations
Content
Hi All,
We are trying to write a if condition which has rel_date_diff() function. But, getting the error that, this function cannot be used as an expression. Below is the column calculation, which we are trying to achieve;
if(transactions2.created IS NOT NULL,if((rel_date_diff(first(transactions2.created,transactions2.created),incidents.created,incidents.rr_id) - (response_reqs.rslv_within *60)) < 0 , 'Within SLA Compliance','SLA Breached'),'Not Applicable')
Notes:
1. transactions2 table has following filters : trans_type = Status change and id1 = Incident.Status.
2. We want to calculate the relative time difference between 2 statuses and compare that value to the Resolution time based on which, we are trying to decide if the custom SLA has been breached or not