For the complete documentation index, see llms.txt. This page is also available as Markdown.

ADDMONTHS

The ADDMONTHS function adds or subtracts a specified number of months from a date. This function is commonly used to calculate future or past dates based on monthly intervals.

Syntax

ADDMONTHS(date, value)

Arguments

  • date: The input date. This can be a date value, measure, or reference.

  • value: The number of months to add or subtract. Use a negative value to subtract months.

Return value

Returns the calculated date.

Examples

ADDMONTHS("05/29/2024", -2)

Returns 03/29/2024 by subtracting 2 months from the input date.

Returns 08/29/2026 by adding 3 months to the input date.

Last updated

Was this helpful?