LOG IN SIGN UP
Documentation

time.sub()

Subtracts a relative time from a time.

Format

TIME
time.sub(TIME t1, TIME t2)

Examples

1
2
3
# var.one_day_earlier will represent the same time yesterday
declare local var.one_day_earlier TIME;
set var.one_day_earlier = time.sub(now, 1d);