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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
RAHEEL
Helper I
Helper I

Formula for Number to Text

Dear All, 

I have a bin column and i want to change the lable of one bin and rest defaults. I am currently using below formula but giving me error mentioned below. Kindly assist. I am unable to find any formula to convert number into text

 

NewBinName = IF('datasheet'[Total Expereince (bins)]=0,"< 3", 'datasheet'[Total Expereince (bins)])

 

Error: Expressions that yield variant data-type cannot be used to define the calculated column

1 ACCEPTED SOLUTION
RAHEEL
Helper I
Helper I

Ok I have used below and it worked for me ....

 

 

NewBinName = IF('datasheet'[Total Expereince (bins)]=0,"< 3",FORMAT('datasheet'[Total Expereince (bins)],"General Number"))
 

View solution in original post

2 REPLIES 2
RAHEEL
Helper I
Helper I

Ok I have used below and it worked for me ....

 

 

NewBinName = IF('datasheet'[Total Expereince (bins)]=0,"< 3",FORMAT('datasheet'[Total Expereince (bins)],"General Number"))
 

BUT the problem now is sorting...after applying new lables it has disturbed the sorting order...

I want sorting to remain with the base variable ?

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.