T-SQL Tutorial

T-SQL MONTH Date Function


MONTH is an date function and returns an integer that represents the month of the specified date.

MONTH Syntax:

MONTH (date)

MONTH Example:

SELECT MONTH('2014-03-01') as Month_1,
MONTH('2014-03-01 08:38:49.1234567 +07:10') as Month_2,
MONTH(SYSDATETIME()) as Month_3;

Month_1Month_2Month_3
333