1 Reply Latest reply on Jul 17, 2013 12:54 PM by Robert Morton

    Datediff day (duh). A word of warning

    Alex Kerin

      Somewhat stupidly I assumed that datediff('day',... would be 0 (or a fraction) if less than 24 hours difference, but it's not because the calculation is based on datepart, so it will always be 1 if the end date is the next day - there could be a 2 minute difference in times (rolling over midnight), but the day difference will still be 1.

       

      datediff('hour',... >24 is what I needed:

       

      datediff.png