Query to find Number of Days in a Month

Kirthiga
Posted by Kirthiga under Sql Server category on | Points: 40 | Views : 804
Declare @Dt datetime='2012-02-04'
select DAY(DATEADD(M,1,@Dt)-DAY(DATEADD(M,1,@Dt))) NoOfDays

Comments or Responses

Login to post response