Forum Discussion
Changing Format of Measure
- 6 years ago
Hi Anonymous ,
The measures when are created take into account the type of data you have so if you are making a sum it will pick up the number, if it's a max of a date column it will pick up a date format.
When you use several formats in a measure then it automatically assumes the format is text, since you are having several different format.
In your case when you add the last step in your switch measure "Invaluid Selection" you are turning the measure into text so the formatting option is turn off.
Work around can be one of two:
- Use FORMAT on each of the CALCULATE syntax similar to:
- FORMAT(CALCULATE([P&L USD'000'),"###,### $")
- Change the "Invalid Selection" by blank() or 0 and then create a new measure that says invalid selection and place it on a visualization on top of the other so one will be on and the other off depending on the selection.
- Use FORMAT on each of the CALCULATE syntax similar to:
Hi Anonymous ,
The measures when are created take into account the type of data you have so if you are making a sum it will pick up the number, if it's a max of a date column it will pick up a date format.
When you use several formats in a measure then it automatically assumes the format is text, since you are having several different format.
In your case when you add the last step in your switch measure "Invaluid Selection" you are turning the measure into text so the formatting option is turn off.
Work around can be one of two:
- Use FORMAT on each of the CALCULATE syntax similar to:
- FORMAT(CALCULATE([P&L USD'000'),"###,### $")
- Change the "Invalid Selection" by blank() or 0 and then create a new measure that says invalid selection and place it on a visualization on top of the other so one will be on and the other off depending on the selection.
- Anonymous6 years agoNot applicable
- NadeemAhamed2 years agoHelper V
I have gone through the above format to apply comma in measures for number.
But its applying only on first 3 decimal.
is it possible to apply comma for first after 3 decimal then for all after 2 decimal.
EX: 1. 23,000
2. 2,12,244
3. 23,23,445
It will be greate if you could able to help me out.
Thank you in advance.
- MFelix2 years agoSuper User