2 Replies Latest reply: Feb 13, 2017 1:12 AM by Apoorva Dhulehole RSS

    Get the count of number of days between two dates if they are greater than zero

    Apoorva Dhulehole

      Hello everyone,


      I have a requirement where I need to get the count of values in a field which are greater than Zero.


      I have three fields namely, "Date Completed", "Target Completion Date" (both are Date fields) and "DateCompleted - TargetCompletionDate". Field, "DateCompleted - TargetCompletionDate" has values which is the difference of "Date Completed" and "Target Completion Date" (ie., No. of days between the two dates) as shown in the attached picture. Now, I need to get the count of these values which are greater than zero.


      I am trying the following expression, count([DateCompleted - TargetCompletionDate])>0 but not getting the desired output. I get -1 as the result which should be 9 as per the attached example.


      Any help on this?


      Thank you.