This document describes how to calculate different units of time between two timestamps using Wrangler. For example, a user may want to calculate the number of months between two calendar dates. This assumes the columns are already timestamps. If they are strings, use the parse-as-simple-date directive to parse the string into a timestamp.
Milliseconds between timestamps
Wrangler includes a diff-date directive that can be used to calculate the milliseconds between two dates.
Years between timestamps
As of 6.4.0, there is no out of the box directive for this, so the set-column directive must be used to calculate the year difference. This can be done as: