You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Returns the last day of the month that contains the specified date, with an optional offset.
30
+
This function returns the last day of the month containing a specified date, with an optional offset.
31
31
32
32
[Transact-SQL Syntax Conventions](../../t-sql/language-elements/transact-sql-syntax-conventions-transact-sql.md)
Date expression specifying the date for which to return the last day of the month.
41
+
*start_date*
42
+
A date expression that specifies the date for which to return the last day of the month.
43
43
44
-
*month_to_add*
45
-
Optional integer expression specifying the number of months to add to *start_date*.
44
+
*month_to_add*
45
+
An optional integer expression that specifies the number of months to add to *start_date*.
46
46
47
-
If this argument is specified, then **EOMONTH** adds the specified number of months to *start_date*, and then returns the last day of the month for the resulting date. If this addition overflows the valid range of dates, then an error is raised.
47
+
If the *month_to_add*argument has a value, then `EOMONTH` adds the specified number of months to *start_date*, and then returns the last day of the month for the resulting date. If this addition overflows the valid range of dates, then `EOMONTH` will raise an error.
48
48
49
49
## Return Type
50
50
**date**
51
51
52
52
## Remarks
53
-
This function can be remoted to [!INCLUDE[ssSQL11](../../includes/sssql11-md.md)] servers and higher. It cannot be remoted to servers with a version lower than [!INCLUDE[ssSQL11](../../includes/sssql11-md.md)].
53
+
The `EOMONTH` function can remote to [!INCLUDE[ssSQL11](../../includes/sssql11-md.md)] servers and higher. It cannot be remote to servers with a version lower than [!INCLUDE[ssSQL11](../../includes/sssql11-md.md)].
0 commit comments