Scriptcase provides the macro sc_date_dif(date1, date1 format, date2, date2 format) to calculate difference between dates in number of days.
date1 - Value or variable containing the first date.
date1 format - Value or variable containing the format of date1.
date2 - Value or variable containing the second date.
date2 format - Value or variable containing the format of date2.
Example 1:
{days} = sc_date_dif({date1}, "yyyy-mm-dd", {date2}, "yyyy-mm-dd");
Example 2:
{days} = sc_date_dif("2006-09-01", "aaaa-mm-dd", "19/01/2007", "dd/mm/aaaa");
Amanda Santos (Migrated deleted Agent)
Comments