Forum Discussion
Format function misbehaving. How to achieve the format that I need?
- 2 years ago
The format applied in Power Query does not direcly affect the format in the report.
In general, I'd recommend using formatting strings on your measures rather than using FORMAT to convert your measure to output a string. FORMAT does not affect the model relationships but it will make a blank return an empty string, so you need to account for that. For example,
formatted = VAR _Value = SUM ( DATA_Budgets[Amount] ) RETURN IF ( NOT ISBLANK ( _Value ), FORMAT ( _Value, "Currency", "nl-NL" ) )
The format applied in Power Query does not direcly affect the format in the report.
In general, I'd recommend using formatting strings on your measures rather than using FORMAT to convert your measure to output a string. FORMAT does not affect the model relationships but it will make a blank return an empty string, so you need to account for that. For example,
formatted =
VAR _Value = SUM ( DATA_Budgets[Amount] )
RETURN
IF (
NOT ISBLANK ( _Value ),
FORMAT ( _Value, "Currency", "nl-NL" )
)Thank you. This was the solution!