DateOffset ( startdate ; monthoffset ; dayoffset ; yearoffset )
Returns a start date, plus or minus a specified number of months, days or years.
Average rating: 4.6 (38 votes) Log in to vote
Intelligent Database, LLC
Function definition: (Copy & paste into FileMaker's Edit Custom Function window)
Returns a start date, plus or minus a specified number of months, days or years. For example, avoids the need for substituting the less accurate "365 * 1.5" (or 547 or 547.5? or 548) for an 18-month offset in date calculations. Also makes it easier to read and remember that the date is adjusted by 18 months (rather than remember what 547 days represents).
Michele Olson, Minnesota
Jul 10, 2012
Thanks for the CF. It worked perfectly. I needed to select records for a 12 month period starting with the month the client wanted and going backwards for 11 months. Your function was great in solving this problem. Thanks for sharing.
Feb 1, 2015
|What about March 31 plus one month? The above gives May 1 but wouldn't you want April 30?|
Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.