Applies ToAccess for Microsoft 365 Access 2024 Access 2021 Access 2019 Access 2016

Returns a string indicating the specified month.

Syntax

MonthName ( month [, abbreviate ] )

The MonthName function syntax has these arguments:

Argument

Description

month

Required. The numeric designation of the month. For example, January is 1, February is 2, and so on.

abbreviate

Optional. Boolean value that indicates if the month name is to be abbreviated. If omitted, the default is False, which means that the month name is not abbreviated.

Query examples

Expression

Results

SELECT Monthname("10") AS Expr1 FROM ProductSales;

Returns the "Full" name of the month for the number representing the 'month'. Result: "October".

SELECT Monthname("10",True) AS MonthTest FROM ProductSales;

Returns the "abbreviated" name of the month for the number representing the 'month' and displays in the column "MonthTest".Result: "Oct" returns the "Full" name of 'month' of the values in the field "DateofSale" from the table "ProductSales" and displays in the column "MonthTest".

Choose the right date function

Need more help?

Want more options?

Explore subscription benefits, browse training courses, learn how to secure your device, and more.

Communities help you ask and answer questions, give feedback, and hear from experts with rich knowledge.