Addition operator +
The addition operator +
computes the sum of its operands.
Expression | Result |
---|---|
+ Duration | Duration |
+ Numeric | Numeric |
Date + Duration | Date |
Duration + Date | Date |
Duration + Duration | Duration |
Numeric + Numeric | Numeric |
Duration + Time | Time |
Time + Duration | Time |
Timestamp + Duration | Timestamp |
Duration + Timestamp | Timestamp |
Examples
+Days(7)
returns 7 days.+Days(-3)
returns -3 days.+5
returns 5.+(-10)
returns -10.[Registered Date] + [Duration]
returns the date you get by adding the Duration column value to the date in the Registered Date column.ToDate("03/20/2013") + Days(3)
returns the date value 3/23/2013.Days(3) + ToDate("03/20/2013")
returns the date value 3/23/2013.Days(7) + Days(3)
returns 10 days.Days(7) + Days(-3)
returns 4 days.5 + 2
returns 7.5 + (-10)
returns -5.[Cost] + [Margin]
returns the price value.Hours(3) + ToTimeOfDay("2:03:29 pm")
returns the time value 5:03:29 PM.ToTimeOfDay("2:03:29 pm") + Hours(3)
returns the time value 5:03:29 PM.[Start Timestamp] + Hours(3)
returns the timestamp resulting from adding 3 hours to the value stored in the Start Timestamp column.Hours(3) + [Start Timestamp]
returns the timestamp resulting from adding 3 hours to the value stored in the Start Timestamp column.