A current limitation in Power BI SWITCH measures (and all Power Pivot actually) is that a SWITCH measure must have a single format. It is currently not possible to conditionally format the measure result based on any criteria - it is one single format only. There are valid use cases where you may want to change the format of the SWITCH measure depending on the result. Consider the following SWITCH statement myMeasure = SUMX(MeasureTable,switch([selected measure], 1,[Total Sales], 2,[Total Cost], 3,[Total Margin], 4,[Chg Sales vs LY %] )) The first 3 results are all currency format, but the last result is a percentage format. This currently can't be controlled. I would like to see an optional 3rd parameter in the SWITCH statement to set an alternate number format.
78 Comments
- do1New MemberAn option to "inherit" the formatting of the source measure would be nice. But it would be even better if a more general solution was provided, similar to how SCOPE statements work in SSAS multidimensional.
- fbcideas_migusrNew MemberGreat idea - I use this feature a lot on a Power Pivot Disconnected Slicer and it would be great to be able to do the same with Power BI.
- ffarah1New MemberThis change would make things a lot simpler and the switch option way more powerful and useful
- fbcideas_migusrNew MemberHere is a simple demo of the problem http://exceleratorbi.com.au/wp-content/uploads/2016/07/switch-measure.gif
- fbcideas_migusrNew MemberMust have, agree. Have several scenarios where it would be the best solution.
- Sohail
Advocate IV
Must have Regards sohail - HansMostafavi
Advocate I
100% agree - DirectorAlwynNew MemberEven more than just the percentage vs. currency, there are lots of situations where you might want text or numbers, especially for error/out of bounds handling where this would be very helpful.
- joeryNew MemberGreat idea, I would love to see this!
- fbcideas_migusrNew Member'@Cheries Mewengkang, what you described will render the number as a text string in a table. This is not the same as changing the number format. If you change the number to a text string, you can't use it in charts or any other place that requires numbers (eg calcs)
Recent ideas
Vertical alignment of data values
Nice addition to word wrap visual titles but... it now causes the data values to not be similarly vertically aligned if one title wraps to three rows and one to two rows. This is more prevalent with...stuartpearson8 hours agoAdvocate IINeeds Votes240Views17likes3CommentsControl Schedule Activation per Environment in Deployment Pipelines
Currently, with the new multiple scheduler feature, we can define multiple run schedules for a Fabric item. However, when using deployment pipelines, there’s no way to control which schedules are act...frithjof_v11 hours agoCommunity ChampionPlanned5.7KViews65likes13CommentsFabric Mirroring for Oracle fails on unconstrained NUMBER columns
Hi, might there be a way to Mirror Oracle database to Fabric when tabels include unconstrained NUMBER columns by setting preconditions for those as it common for Oracle databases? BR, MagnusMagnusBerglund1 day agoNew MemberNew23Views0likes0CommentsEmbedded Power BI: allow 12/24-hour clock setting independent of formatLocale
Problem In Power BI embedded reports (app-owns-data, JavaScript SDK), localeSettings.formatLocale is the only way to influence date and time display. The hour cycle (12 or 24 hour) is tied to th...VijaySama5882 days agoNew MemberNew6Views0likes0CommentsAdd Initial Horizontal Scroll Position to Matrix and Table Visuals
Please add an option to Power BI Matrix and Table visuals that allows report developers to configure the initial horizontal scroll position when the visual loads. Suggested setting: Format visual >...Panteras012 days agoFrequent VisitorNew3Views0likes0Comments