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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
mithiladas02
Helper I
Helper I

Concatenate syntax

Hi,

 

I am using this 

Test=cancatenate(format(divide([a],[b]), "#.0%" & Unichar(10)), (" (" & if [a]=0, "0")& "/" & if ([b]=0, "0",[b])& ")"))

using thisParenthesis.jpg syntex i am getting parenthesis for all except zero. PLease see the picture. I want to remove Parenthesis from 0 only and keep parenthesis to all value. I have tried to write the syntex like below.

 

Test=cancatenate(format(divide([a],[b]), "#.0%" & Unichar(10)),  if format([a]=0, "0","(#,#)")& "/" & if ([b]=0, "0",format([b],"(#,#")))

 

but results coming like (123)/(456) and with zero it didnt show () sign. 

I want my result (123/456) and when any row comes 0,it will show only 0.

 

Please help me to figure out this syntex.

 

Thanks in advance.

 

1 ACCEPTED SOLUTION
lbendlin
Super User
Super User

Test=IF(a=0,0,format(divide([a],[b]), "#.0%") & Unichar(10) & "(" & a & "/" & b & ")")

View solution in original post

1 REPLY 1
lbendlin
Super User
Super User

Test=IF(a=0,0,format(divide([a],[b]), "#.0%") & Unichar(10) & "(" & a & "/" & b & ")")

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.

Top Solution Authors
Top Kudoed Authors