Find out the month name in two months time : DATENAME « Date Timezone « SQL Server / T-SQL






Find out the month name in two months time


2> -- Find out the month name in two months time:
3>
4> SELECT DATENAME(mm,DATEADD(mm,2,GETDATE()))
5> GO

------------------------------
December

(1 rows affected)
1>
           
       








Related examples in the same category

1.DATENAME returns the part of the date in a literal form.
2.Using the DATENAME() Function
3.DATENAME: return the part of the date in a literal form
4.DATENAME(month, '4-29-1988') returns a string containing the descriptive name
5.select DATENAME(day, '2002-09-30 11:35:00')
6.select DATENAME(year, '2002-09-30 11:35:00')
7.select DATENAME(hour, '2002-09-30 11:35:00')
8.select DATENAME(minute, '2002-09-30 11:35:00')
9.select DATENAME(second, '2002-09-30 11:35:00')
10.select DATENAME(quarter, '2002-09-30 11:35:00')
11.select DATENAME(dayofyear, '2002-09-30 11:35:00')
12.select DATENAME(week, '2002-09-30 11:35:00')
13.select DATENAME(weekday, '2002-09-30 11:35:00')