Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
ChubbChubb
Helper I
Helper I

DAX formula not working

I'm triyng to add a subtitle to acard to display national data.

 

The formula that works looks like this 

KPI Attendance Target = format(Product('Academy Info'[Attendance Target]),"KPI #%"&""). It is turning a percentage column into a text column to then use as a subtitle on the card.
 
I have tried to use the same formula for a different set of data 
Nat Ebacc Entry = format(Product('National Headline Data'[Nat Ebacc Entry]),"Nat #.#%"&"")
 
and instead I get this
ChubbChubb_1-1706785173673.png

 

I find that If I change the "Nat" to "KPI" it works fine, but if I use the letters N or S they get changed to 41&17 and code doesn't work.

 

I have checked that the two source columns are set up exactly the same way, just can't fathom it out?

 

TIA 


 

 
1 ACCEPTED SOLUTION
olgad
Super User
Super User

Hi, dont place NAT  into format function

 "Nat " & format(Product('Academy Info'[Attendance Target]," #%"&"")

DID I ANSWER YOUR QUESTION? PLEASE MARK MY POST AS A SOLUTION! APPRECIATE YOUR KUDO/LIKE!
PROUD TO BE A SUPER USER!
Best Stories, Interesting Cases: PowerBI Storytime Newsletter
Linkedin Profile: Linkedin
YouTube Channel: PowerBI Storytime

View solution in original post

2 REPLIES 2
olgad
Super User
Super User

Hi, dont place NAT  into format function

 "Nat " & format(Product('Academy Info'[Attendance Target]," #%"&"")

DID I ANSWER YOUR QUESTION? PLEASE MARK MY POST AS A SOLUTION! APPRECIATE YOUR KUDO/LIKE!
PROUD TO BE A SUPER USER!
Best Stories, Interesting Cases: PowerBI Storytime Newsletter
Linkedin Profile: Linkedin
YouTube Channel: PowerBI Storytime

Thank you for that, I had copied the forumla from somewhere else so wasn't sure on it. Do you know why it was replacing the letters for number?

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

Find out what's new and trending in the Fabric community.