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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
harshagraj
Post Partisan
Post Partisan

Divide By Zero Error- Live Connection

Hi All I am using a Live connection. I have two columns Manger Expectation and User rating. Trying to calculate Skill Index. 
Created a measure Skill Index= Divide(Average(User Rating)/ Average(Manager Expectation),0).
Now need to find out the Count of Users who are "Met" expectations. So used below Calculated measures.

Comp_Flag_LOD = IF([Skill Index]>=1,"Met","Not Met")
Comp_Met_LOD = CALCULATE(DISTINCTCOUNT('Table_RATING'[L3_NAME]),FILTER('Table_RATING',[Comp_Flag_LOD]="Met")).

I am getting the below divide by error when i use Comp_Met_LOD in Card.zero error.PNG
5 REPLIES 5
Anonymous
Not applicable

@harshagraj 
Try create the two dax with columns rather than a measures:

Index column = Divide([User Rating],[Manager Expectation],0).

Comp_Flag_LOD column = IF([Skill Index]>=1,"Met","Not Met")

 

If not working or you really need measures, maybe  show us some sample? 

 

Paul Zheng _ Community Support Team
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @Anonymous  thanks for the reply. I have columns as Competancy, User Rating, Manager Expectations. I created a calculated measure Skill Index = Divide(Average[User Rating],Average[Manager Expectation],0) Because user may have multiple competancy so i need to aggregate it.
Now i need distinct count of competancy wher the user is met(Skill Index>=1) and which is a huge data.

I tried creating a index Column but i got a error saying Average cannot be used in Live connection.
I am so sorry i cant share the data as it is highly sensitive. 

Anonymous
Not applicable

Try this measure. Instead of "/" use "," inside Divide

Skill Index= Divide(Average(User Rating),Average(Manager Expectation),0)

Hi @Anonymous  sorry my bad. Its a typo. Yes i had put , only and not /

@harshagraj , then it should have worked. Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.

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
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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