Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Team,
I'm trying to build a donut in PBI Table. I'm using this code to do so. However, as per the blog, >= 100% shows full solid circle with tick mark inside. However, I don't want to show tick. Even for 100% and greater I want percentage to display.
I tried this code.
Pie Chart SVG =
var PercentValue = IF([%Change] >.9999, [%Change], [%Change] ) var PercentA = PercentValue * 360
var CirclePercent = 180 - PercentA var ShortDistance = if(CirclePercent < 0, 1,0) var Radians = RADIANS(CirclePercent) var XArcEnd = sin(Radians) var YArcEnd = cos(Radians)
var circle = IF(PercentValue = 1, "<circle cx='0' cy='0' r='1' fill='green' />", IF(PercentValue > 1, "<circle cx='0' cy='0' r='1' fill='red' />", "<circle cx='0' cy='0' r='0.8' fill='white' />"))
var textvalue = IF(PercentValue >= .9999, "<text x='0' y='0' font-size='0.6' alignment-baseline='middle' text-anchor='middle' fill='white'>"&FORMAT(PercentValue,"0%")&"</text>", "<text x='0' y='0' text-anchor='middle' alignment-baseline='middle' font-size='0.6'>"&FORMAT(PercentValue,"0%")&"</text>")
RETURN
"data:image/svg+xml;utf8,<svg
xmlns='http://www.w3.org/2000/svg'
viewBox='-1 -1 2 2'>
<circle cx='0' cy='0' r='1' fill='lightgrey' />
<path d='M 0 -1 A 1 1 0 " & ShortDistance & " 1 " & XArcEnd & " " & YArcEnd & " L 0 0 z' fill='green'></path>"&
circle&textvalue&"
</svg>"for one of the rows (marked) I'm getting extra outer green color
not sure from where I'm getting this. Can @KerKol please help me fixing this?
Thanks!
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 58 | |
| 45 | |
| 42 | |
| 21 | |
| 18 |
| User | Count |
|---|---|
| 172 | |
| 107 | |
| 92 | |
| 54 | |
| 46 |