Format DAX Function in Power BI

The FORMAT DAX function in Power BI converts a value to the text format specified by the format_string.

The function has the following parameters:

DAX Syntax FORMAT(value, format_string)

Example: Let’s create a measure.

DAX

Format Measure = FORMAT(TODAY(), "YYYY-MM")

The output of the above dax code is shown below:

FORMAT dax function in Power BI

Example: Let's create a Calculated column.

DAX

Formatted Column = FORMAT(Query11[Year], "yyyymm")

The output of the above dax code is shown below:

FORMAT dax function in Power BI