Date & Time WEEKDAY Int Date String Method (optional) Int The WEEKDAY() function returns the weekday of given date. If the method is 1 (default) WEEKDAY() returns 1 for sunday, 2 for monday,.. If the method is 2, monday is 1, tuesday 2, ... and if the method is 3 WEEKDAY() returns 0 for monday, 1 for tuesday,... WEEKDAY(date; method) WEEKDAY("2002-02-22"; 2) returns 5 DAYNAME DAYS360 Int Date1 String Date2 String Method Boolean The DAYS360() function returns the number of days from date1 to date2 using a 360-day calendar in which all months are assumed to have 30 days. If method is false (default) the US method will be used, the European otherwise. DAYS360(date1; date2; method) DAYS360("2/22/2002"; "4/21/2002"; FALSE) returns 59 DAYS MONTHS WEEKS YEARS TIMEVALUE Float Time String The TIMEVALUE() function returns a number (between 0 and 1) representing the time of day. TIMEVALUE(time) TIMEVALUE("10:05:02") returns 0.42 DATEVALUE DATEVALUE Int Date String The DATEVALUE function returns a number representing the day, i.e the number of days elapsed since December 31, 1899. DATEVALUE(date) DATEVALUE("2/22/2002") returns 37309 TIMEVALUE EDATE Date Date String Months Int The EDATE functions returns the date that is specified by a given date and a number of months before or after that date. EDATE(date; months) EDATE("2/22/2002"; 3) returns "5/22/2002" EDATE("3/31/2002"; -1) returns "2/28/2002" DATE EOMONTH EOMONTH Date Date String Months Int The EOMONTH functions returns the last day in the month specified by a date and the number of months from that date. EOMONTH(date; months) EOMONTH("2/22/2002"; 3) returns "5/31/2002" EOMONTH("3/12/2002"; -1) returns "2/28/2002" EOMONTH("3/12/2002"; 0) returns "3/31/2002" EDATE MONTH YEAR Int Date String The YEAR functions returns the year of a date. If no parameter is specified the current year gets returned. YEAR(date) YEAR("2/22/2002") returns 2002 YEAR(2323.1285) returns 1906 DAY MONTH MONTH Int Date String The MONTH functions returns the month of a date. If no parameter is specified the current month gets returned. MONTH(date) MONTH("2/22/2002") returns 2 MONTH(2323.1285) returns 5 DAY YEAR DAY Int Date String The DAY functions returns the day of a date. If no parameter is specified the current day gets returned. DAY(date) DAY("2/22/2002") returns 22 DAY(2323.1285) returns 11 MONTH YEAR HOUR Int Time String The HOUR functions returns the hour of a time. If no parameter is specified the current hour gets returned. HOUR(time) HOUR("22:10:12") returns 22 HOUR(0.1285) returns 3 MINUTE SECOND MINUTE Int Time String The MINUTE functions returns the minutes of a time. If no parameter is specified the current minute is returned. MINUTE(time) MINUTE("22:10:12") returns 10 MINUTE(0.1234) returns 57 HOUR SECOND SECOND Int Time String The SECOND functions returns the seconds of a time. If no parameter is specified the current second is returned. SECOND(time) SECOND("22:10:12") returns 12 SECOND(0.1234) returns 42 HOUR MINUTE WEEKS Int First (earlier) date value String Second date value String Calculation mode Int The WEEKS() function returns the difference between two dates in weeks.The third parameter indicates the calculation mode: if the mode is 0, WEEKS() returns the maximal possible number of weeks between those days. If the mode is 1, it only returns the number of whole weeks in between. WEEKS(date2; date1; mode) WEEKS("2002-02-18"; "2002-02-26"; 0) returns 1, because there is one week and 1 day in between WEEKS("2002-19-02"; "2002-19-02"; 1) returns 0, because there is not a whole week in between, starting at the first day of the week (monday or sunday, depending on your local settings) MONTHS Int First (earlier) date value String Second date value String Calculation mode Int The MONTHS() function returns the difference between two dates in months.The third parameter indicates the calculation mode: if the mode is 0, MONTHS() returns the maximal possible number of months between those days. If the mode is 1, it only returns the number of complete months in between. MONTHS(date2; date1; mode) MONTHS("2002-01-18"; "2002-02-26"; 0) returns 1, because there is 1 month and 8 days in between MONTHS("2002-01-19"; "2002-02-26"; 1) returns 0, because there is not a whole month in between, starting at the first day of the month YEARS Int First (earlier) date value String Second date value String Calculation mode Int The YEARS() function returns the difference between two dates in years. The third parameter indicates the calculation mode: if the mode is 0, YEARS() returns the maximal possible number of years between those days. If the mode is 1, it only returns whole years, starting at the 1st Jan and ending on the 31st Dec. YEARS(date2; date1; mode) YEARS("2001-02-19"; "2002-02-26"; 0) returns 1, because there is one year and 7 days in between YEARS("2002-02-19"; "2002-02-26"; 1) returns 0, because there is not a whole year in between, starting at the first day of the year DAYS Int First (earlier) date value String Second date value String The DAYS() function returns the difference between two dates in days. DAYS(date2; date1) DAYS("2002-02-22"; "2002-02-26") returns 4 DAYOFYEAR Int Year Int Month Int Day Int The DAYOFYEAR() function returns the number of the day in the year (1...365). DAYOFYEAR(year;month;date) DAYOFYEAR(2000;12;1) returns 336 DAYOFYEAR(2000;2;29) returns 60 DATE String Year Int Month Int Day Int The DATE() function returns the date formatted with local parameters. DATE(year;month;date) DATE(2000;5;5) returns Friday 05 May 2000 TIME String Hours Int Minutes Int Seconds Int The TIME() function returns the time formatted with local parameters. TIME(hours;minutes;seconds) TIME(10;2;2) returns 10:02:02 TIME(10;70;0) returns 11:10:0 TIME(10;-40;0) returns 9:20:0 HOURS Int Time String The HOURS() function returns the value of the hours in a time expression. HOURS(time) HOURS("10:5:2") returns 10 ISLEAPYEAR Boolean Year Int The function ISLEAPYEAR() returns True if the given year is leap. ISLEAPYEAR(year) ISLEAPYEAR(2000) returns True DAYSINMONTH Int Year Int Month Int The function DAYSINMONTH() returns number of days in the given year and month. DAYSINMONTH(year;month) DAYSINMONTH(2000;2) returns 29 DAYSINYEAR Int Year Int The function DAYSINYEAR() returns the number of days in the given year. DAYSINYEAR(year) DAYSINYEAR(2000) returns 366 WEEKSINYEAR Int Year Int The function WEEKSINYEAR() returns the number of weeks in the given year. WEEKSINYEAR(year) WEEKSINYEAR(2000) returns 52 MINUTES Int Time String The MINUTES() function returns the value of the minutes in a time expression. MINUTES(time) MINUTES("10:5:2") returns 5 SECONDS Int Time String The SECONDS() function returns the value of the seconds in a time expression. SECONDS(time) SECONDS("10:5:2") returns 2 DAYNAME String Number of day in week (1..7) Int The DAYNAME() function returns the name of the day of the week (1..7). In some countries the first day of the week is Monday, while in others the first day of the week is Sunday. DAYNAME(weekday) DAYNAME(1) returns Monday (if the week starts on Monday) WEEKDAY MONTHNAME String Number of month (1..12) Int The MONTHNAME() function returns the name of the month (1...12). MONTHNAME(number) MONTHNAME(5) returns May CURRENTDATE Date The CURRENTDATE() function returns the current date. It is equivalent to the TODAY function. CURRENTDATE() CURRENTDATE() returns "Saturday 13 April 2002" CURRENTTIME TODAY TODAY Date The TODAY() function returns the current date. TODAY() TODAY() returns "Saturday 13 April 2002" CURRENTTIME NOW NOW Date The NOW() function returns the current date and time. It is identical with CURRENTDATETIME and provided for compatibility with other applications. NOW() NOW() returns "Saturday 13 April 2002 19:12:01" CURRENTTIME TODAY CURRENTDATETIME Date The CURRENTDATETIME() function returns the current date and time. CURRENTDATETIME() CURRENTDATETIME() returns "Saturday 13 April 2002 19:12:01" CURRENTTIME Date The CURRENTTIME() function returns the current time formatted with local parameters. CURRENTTIME() CURRENTTIME() returns "19:12:01" EASTERSUNDAY Date Year Int The EASTERSUNDAY() function returns the date which corresponds to Easter Sunday in the year given as the parameter. EASTERSUNDAY(year) EASTERSUNDAY(2003) returns "20th April 2003" ISOWEEKNUM Int Date String The ISOWEEKNUM() function returns number of the week which the date falls into. Note that this function is compliant with the ISO8601 standard: a week always begins on a Monday, and ends on a Sunday. The first week of a year is that week which contains the first Thursday of the year. ISOWEEKNUM(date) ISOWEEKNUM(A1) returns 51 when A1 is "21st of Dec".