Hi,
Can anyone enlighten if there is a date subtraction calculation facility?
I want to create a new date by subtracting x amount of days from a specific date from another field.
Ever the optimist, I thought it might be as simple as DATEADD(OLDDATE-42) but I’m wrong. :-)
Thanks in advance.
You are almost there. Try this: DATEADD([DATEFIELD];0;0;0;-42;0;0;0)
with return type date.
-
This reply was modified 2 years, 11 months ago by Daniel Leu.
Thanks for the prompt reply Daniel.
The result does return a value but it only shows the Year. How can I get the full date in the format dd-mm-yy?
Thanks
Double check the format settings on your calculation field to make sure they’re set to the format you want. The settings are at the bottom of the field settings area when the field is selected (you’ll have to scroll a bit).
Thanks Sam. Spot on.
Although the return value appeared to be showing the year only, the actual form was showing the full date.
All sorted, many thanks.