< Day Day Up > |
Month()Category: Date Syntax: Month ( Date ) Parameters: Date ”Any valid date (1/1/0001 “12/31/4000). The parameter should be a string containing a date (for example, "3/17/2004" ), an expression with a date result (for example, Date (6, 29, 1969) ), or an integer that represents a serialized date value (for example, 718977 ). Description: Returns the month number (1 “12) for any valid date (1/1/0001 “12/31/4000). Examples: Month ("5/1/2000") Returns 5 . Month (718977) Returns 6 . Month (Get (CurrentDate)) Returns 3 (if the current date is in March). Comments: The numeric value returned by Month() can be used in mathematical calculations as well as within the Date() function to construct a new date. One common use of the Month() function is to build a formula that returns the quarter of a given date: Case( Month(myDate)<4, "First Quarter", Month(myDate)<7, "Second Quarter", Month(myDate)<9, "Third Quarter", "Fourth Quarter" ) |
< Day Day Up > |