Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.
Hi all - I'm still learning (lots), I'm having trouble getting my calculation group for current and previous year to format in thousands to this £123k, from this (£123,123.00).
I'm sure this is simple to do, but after reading looking online, and see possible solution I'm still unable to resolve. Could I please ask for help?
"£"##0,"k";-"£"##0, does not give the required results
Have I missed something simple, and I being simple?
Thank you for look at this
Solved! Go to Solution.
Hi @101Mathew ,
If I understand correctly you are setting the format string expression for the Calculation Item? I believe you need to wrap the expression in quotation marks for calculation items - see Matt Allington's blog post as an example https://exceleratorbi.com.au/dynamic-formatting-of-switch-measures/
Where the expression already has quotation marks in it I've had success replacing them with /. So for some calculation items I've had to go from "£"#,0.00;-"£"#,0.00;"£"#,0.00 to "\£#,0.00;-\£#,0.00;\£#,0.00" - I believe this would work in your example if you put the required amount of decimal places in?
Not sure if that's what you are after
Tom
Hi @101Mathew ,
If I understand correctly you are setting the format string expression for the Calculation Item? I believe you need to wrap the expression in quotation marks for calculation items - see Matt Allington's blog post as an example https://exceleratorbi.com.au/dynamic-formatting-of-switch-measures/
Where the expression already has quotation marks in it I've had success replacing them with /. So for some calculation items I've had to go from "£"#,0.00;-"£"#,0.00;"£"#,0.00 to "\£#,0.00;-\£#,0.00;\£#,0.00" - I believe this would work in your example if you put the required amount of decimal places in?
Not sure if that's what you are after
Tom
@FrankAT and @Greg_Deckler - thank you both so much for your time looking at this.
Your solutions works, but not quite what I'm looking for
1 If I can format calculation group item, I need to affect less measure
2 If I this can be done via calculation group script formatting, I can have my base value formatted differently
3 Ideally I would love to get the k on the number like £123k to denote £123,123.12
I thank you again for your reply (which is still very useful)
Hi @101Mathew ,
Consider a card showing total rows as follows:
Suppose I want to show the number in thousands, so I can use the format options for this visual to do so:
We will something as below:
This can be modified against number of decimal places as well.
Is this what you are looking for?
Thanks,
Pragati
@Pragati11 - Thank you kindly
Again a solution but not one that meets the requirements.
Please see my last reply
Again thank you so much to helping 😉
Regards,
Mathew
Hi @101Mathew ,
May be I don't understand your last response properly.
Do you want this with ZERO decimal places?
Add some screenshots to your issue not just the formatting you are looking for. Screenshots sometimes make things clear or may be explain your self again as I don't understand your last response properly.
Thanks,
Pragati
Hi @Pragati11 ,
But the below does not show the full intent
Using tabular editor, allows calculation groups within Power BI models - On each element of the calculation group, tabular editor lets you use format scripts
The question is do you get the above, via custom format within tabular editor
Hi @101Mathew ,
In Power BI, under Model tab, you do have an option to give custom formats to columns like shown below:
But not sure if this solves your issue.
Thanks,
Pragati
@Pragati11 Not really - but a the custom format that works on that might also work on the tabular editor format string
Hi @101Mathew ,
Yes I think it should work.
Have you resolved your issue?
Can you mark the appropriate solutions to this thread so others can benefit from it?
Thanks,
Pragati
Hi @101Mathew
take a look at the following solution:
With kind regards from the town where the legend of the 'Pied Piper of Hamelin' is at home
FrankAT (Proud to be a Datanaut)
@101Mathew If I remember correctly when this came up before, you will need to create a measure that divides by 1000 and then use the specified format.
Check out the November 2023 Power BI update to learn about new features.