Date and Time Functions

These functions help you create calculations based on dates and time. Many of the functions in DAX are similar to the Excel date and time functions. However, DAX functions use a datetime data type, and can take values from a column as an argument.

In this category

FunctionDescription
CALENDARReturns a table with a single column named “Date” that contains a contiguous set of dates.
CALENDARAUTOReturns a table with a single column named “Date” that contains a contiguous set of dates.
DATEReturns the specified date in datetime format.
DATEDIFFReturns the count of interval boundaries crossed between two dates.
DATEVALUEConverts a date in the form of text to a date in datetime format.
DAYReturns the day of the month, a number from 1 to 31.
EDATEReturns the date that is the indicated number of months before or after the start date.
EOMONTHReturns the date in datetime format of the last day of the month, before or after a specified number of months.
HOURReturns the hour as a number from 0 (12:00 A.M.) to 23 (11:00 P.M.).
MINUTEReturns the minute as a number from 0 to 59, given a date and time value.
MONTHReturns the month as a number from 1 (January) to 12 (December).
NOWReturns the current date and time in datetime format.
SECONDReturns the seconds of a time value, as a number from 0 to 59.
TIMEConverts hours, minutes, and seconds given as numbers to a time in datetime format.
TIMEVALUEConverts a time in text format to a time in datetime format.
TODAYReturns the current date.
WEEKDAYReturns a number from 1 to 7 identifying the day of the week of a date.
WEEKNUMReturns the week number for the given date and year according to the return_type value.
YEARReturns the year of a date as a four digit integer in the range 1900-9999.
YEARFRACCalculates the fraction of the year represented by the number of whole days between two dates.

***** Related Blog Posts *****
60 Page DAX Formula Reference Guide Download Now Available
Show Only Top Or Bottom Results Using Ranking Formula Techniques – Power BI & DAX

***** Related Video Tutorials *****
Ultimate Beginners Guide to DAX

What Is DAX? & Why Do You Need To Learn It – (1.2) Ultimate Beginner Guide to DAX
Formula Syntax, Comments & Variables – (1.6) Ultimate Beginners Guide to DAX
Examples Of Advanced DAX – (1.18) Ultimate Beginners Guide to DAX

***** Related Course Modules *****
Ultimate Beginners Guide to DAX
Mastering DAX Calculations
Solving Analytical Scenarios w/ Power BI and DAX
DAX Formula Deep Dives
Advanced DAX Combinations

***** Related Support Forum Posts*****
Mastering DAX Calculations: What Is DAX?
Understanding DAX Formula
Developing Complex Dax functions
Data Types And Operators

Center of Excellence

DOWNLOAD


Download our comprehensive DAX Formula Reference Guide as perfect companion as you learn how to use DAX formulas within Power BI.


Download DAX Formulas Reference Guide
Download DAX Formula Reference Guide
Membership