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

Try your skills in the Power BI Dataviz World Championship! Round one ends June 26. Join now

Reply
Anonymous
Not applicable

Percente

HI everybody,

Have I troble to do percent 

 

What i need

Count i "cidades" and divide foir all "cidades"

PabloSosa_1-1641381548811.png


What i tried



PabloSosa_0-1641381491019.png

 

WHen i put in the graph 

PabloSosa_2-1641381601372.png

 

Thanks

 

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Anonymous ,

 

Assume you have already get the [cidades] column correctly, then you could create a measure like below:

measure = 
var a = calculate(countrow('atendimentos'),filter(all('atendimentos'),[cidades] = selectedvalue('atendimentos'[cidades])))
var b = calculate(countrow('atendimentos'),ALL('atendimentos'))
return

divide(a,b)

If I misunderstood your meaning, please show some sample data in text format and the expected result you want.

 

Best Regards,

Jay

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi @Anonymous ,

 

Assume you have already get the [cidades] column correctly, then you could create a measure like below:

measure = 
var a = calculate(countrow('atendimentos'),filter(all('atendimentos'),[cidades] = selectedvalue('atendimentos'[cidades])))
var b = calculate(countrow('atendimentos'),ALL('atendimentos'))
return

divide(a,b)

If I misunderstood your meaning, please show some sample data in text format and the expected result you want.

 

Best Regards,

Jay

amitchandak
Super User
Super User

@Anonymous , You can not use slicer value in a column, You need to create a measure

 

refer

 

Percent of SubTotal or Total: https://www.youtube.com/watch?v=6jTildcV2ho&list=PLPaNVDMhUXGaaqV92SBD5X2hk3TMNlHhb&index=37

 

Percent of Total- https://www.youtube.com/watch?v=uO3ojDPOpcg&list=PLPaNVDMhUXGZNyKU0PgG2g3P0c6CPjMnj&index=7

 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Fabric Data Days is here Carousel

Fabric Data Days 2026

Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.

May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 2026 Power BI update to learn about new features.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.