The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hello,
I am trying to extract the month name from the date column using the format([date], "MMMM"). But I am getting different month names. Help me to get the correct month name.
Pls refer to the image attached:
Solved! Go to Solution.
I am no expert, I think this is what is happening.
"mmm" format is applicable for Date data type whereas MONTH(Date[Date]) doesn't return date, but a number and "mmm" is no longer relevant and returns incorrect result.
FORMAT function (DAX) - DAX | Microsoft Learn
The format strings supported as an argument to the DAX FORMAT function are based on the format strings used by Visual Basic (OLE Automation), not on the format strings used by the .NET Framework. Therefore, you might get unexpected results or an error if the argument doesn't match any defined format strings. For example, "p" as an abbreviation for "Percent" isn't supported. Strings that you provide as an argument to the FORMAT function that aren't included in the list of predefined format strings are handled as part of a custom format string, or as a string literal.
User | Count |
---|---|
28 | |
11 | |
8 | |
6 | |
5 |
User | Count |
---|---|
35 | |
14 | |
12 | |
9 | |
7 |