Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Hello everyone,
I am currently facing an issue with a field parameter in Power BI that switches between two measures. Both measures are formatted as numbers (not text) and are supposed to display with thousand separators by default. The thousand separators can be correctly enabled in the visualization settings and initially appear as expected.
However, the following problem occurs:
After saving and closing the report, and then reopening it, the thousand separators disappear for one of the two measures in the visual.
This happens even though the measures are correctly formatted as numbers, and the formatting in the visual is also correctly set.
I have already tried:
Defining the formatting directly in the measure (using the FORMAT function), which results in a text representation and prevents calculations and sorting.
Controlling the formatting through the visualization settings, which does not remain stable after saving and reopening.
Does anyone have an idea how to ensure that the formatting of thousand separators for field parameters in Power BI remains stable?
Thank you for your support!
Solved! Go to Solution.
Hi @ThisIsBlecki , Thank you for reaching out to the Microsoft Community Forum.
The best fix is to use a calculation group instead of field parameters. Calculation groups let you switch between measures just like field parameters do, but they also allow you to set and lock in formatting directly in the data model. To do this, you’ll need to use Tabular Editor, a free external tool. In Tabular Editor, you can create a calculation group, add a calculation item for each measure and assign each one a format string such as:
"#,##0". This ensures that when a user switches between measures, the formatting, including thousand separators remains consistent, even after saving, reopening or publishing the report.
If you’re not ready to use calculation groups yet, you can still try setting consistent formatting in Model View. Select each measure, set the data type to Whole Number or Decimal Number, enable the thousand separator and use the same number of decimal places. Just know that this approach might not always stick when field parameters are involved. Also, double-check your regional settings to ensure you’re using a locale like English (United States), which uses commas for thousand separators. And make sure you're running the latest version of Power BI Desktop, since some older versions had bugs related to formatting persistence.
If this helped solve the issue, please consider marking it 'Accept as Solution' so others with similar queries may find it more easily. If not, please share the details, always happy to help.
Thank you.
Hey @v-hashadapu,
thank you for your solution.
Why do i need the Tabular Editor? As i see, i can create Calculation groups directly in PBI.
Hi @ThisIsBlecki , You're correct, as of recent Power BI Desktop updates, you can create calculation groups directly in the Model view without needing Tabular Editor. Just an old habit of giving this suggestion, for which i apologize. Thank you.
Hi @ThisIsBlecki , Thank you for reaching out to the Microsoft Community Forum.
The best fix is to use a calculation group instead of field parameters. Calculation groups let you switch between measures just like field parameters do, but they also allow you to set and lock in formatting directly in the data model. To do this, you’ll need to use Tabular Editor, a free external tool. In Tabular Editor, you can create a calculation group, add a calculation item for each measure and assign each one a format string such as:
"#,##0". This ensures that when a user switches between measures, the formatting, including thousand separators remains consistent, even after saving, reopening or publishing the report.
If you’re not ready to use calculation groups yet, you can still try setting consistent formatting in Model View. Select each measure, set the data type to Whole Number or Decimal Number, enable the thousand separator and use the same number of decimal places. Just know that this approach might not always stick when field parameters are involved. Also, double-check your regional settings to ensure you’re using a locale like English (United States), which uses commas for thousand separators. And make sure you're running the latest version of Power BI Desktop, since some older versions had bugs related to formatting persistence.
If this helped solve the issue, please consider marking it 'Accept as Solution' so others with similar queries may find it more easily. If not, please share the details, always happy to help.
Thank you.
User | Count |
---|---|
84 | |
82 | |
66 | |
52 | |
46 |
User | Count |
---|---|
100 | |
48 | |
42 | |
39 | |
38 |