Quantcast
Channel: dBforums – Everything on Databases, Design, Developers and Administrators
Viewing all articles
Browse latest Browse all 13329

Days in a month

$
0
0
Hello!

I have a month and a year "mm/yyyy". I want to calculate the number of days in that specific month of that year. So for example: 01/2013 would be 31. The number of days are important because I have a calculations I need to do off of that. I have seen the DateDiff function to find the number of days in the current month, but I do not know how to translate this into what I need.

Field: DateDiff("d",Date()-(Day(Date()- 1)), DateSerial(Year _
(Date()),(Month(Date())+1),1))

The Table I am pulling from is called 'HOURSdata' with a field called [RDate]. Would anyone know how DateDiff could be used to my advantage, or should I use another function?

Viewing all articles
Browse latest Browse all 13329

Trending Articles