Archives of the TeradataForum
Message Posted: Wed, 07 Mar 2002 @ 00:58:14 GMT
Starting with V2R3 the new date arithmetic looks something like this to get days:
sel current_date - ('2002/02/01' (date)) (interval day(3));
You can specify your interval in days, months to days, etc. The number in the parenthesis (3) is the number of digits to hold the answer. If you don't provide sufficient digits it will error with an overflow.
You can also add and subtract intervals to/from dates, add/subtract intervals to get other intervals, etc.
|Copyright 2016 - All Rights Reserved|
|Last Modified: 23 Jun 2019|