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 August 31st. Request your voucher.

Reply
Pmrs
Regular Visitor

Need help-dax measure

Hi Team,

I need help on Dax measure. I have to calculate Total targets calls.

Attached the sample file for reference.

If you take an example of an account with repd_visit frequency=12(descriptor cyclic), which means the account is expected to be called (phone call or phone visit or visit) 12 times an year. Hence the reporting is based on each cycle (12 an year)

Total target calls is 1(12 calls a year/12 cycles)

This is my requirement please help me on this

https://drive.google.com/file/d/1-iuNfAzyOg0pR7Mthm4Lkc73zvR9tV08/view?usp=drivesdk

1 ACCEPTED SOLUTION
v-tsaipranay
Community Support
Community Support

Hi @Pmrs ,


After thoroughly reviewing the details you provided, I was able to reproduce the scenario, and it worked on my end. I have used it as sample data on my end and successfully implemented it.     

I am also including .pbix file for your better understanding, please have a look into it:

Thank you for using Microsoft Community Forum.

 

View solution in original post

9 REPLIES 9
v-tsaipranay
Community Support
Community Support

Hi @Pmrs ,

 

We haven’t received an update from you in some time. Could you please let us know if the issue has been resolved?
If you still require support, please let us know, we are happy to assist you.

 

Thank you.

v-tsaipranay
Community Support
Community Support

Hi @Pmrs ,

 

I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions. Also thank you @Hizqeel  for your helpful response.


Thank yo

Hizqeel
Regular Visitor

Hi everyone,

I'm working on an Inventory Valuation measure in Power BI, but the numbers aren't adding up correctly. I have two fact tables — one is a Transaction table that holds Units Sold for each Product ID, and another is an Inventory table that includes Purchases for each Product ID. My goal is to calculate how much inventory is on hand by subtracting total units sold from total purchases, and then multiplying that result by the product's cost price from the Product table.

The problem is that my Inventory Valuation measure is giving me a result of $1.4B, but based on the data, it should be closer to $586M. I'm using a DAX measure that sums purchases and sales per product using SUMX over VALUES(Product[Product ID]), and multiplies that by the cost price. But I think the way Power BI is aggregating values from two separate fact tables might be causing this issue — maybe it's duplicating cost price or not respecting granularity properly.

I’ve made sure my relationships are correct. Transaction is many-to-one with Product, and Product is one-to-many with Inventory. I'm also using a Date table to slice by time.

I just want to understand why the number is so inflated and how to correctly handle calculations like these that involve two different fact tables and a lookup to cost price. Any help, feedback, or advice would be appreciated.

Thanks a lot!

In the table view (attached), the Inventory On Hand, Cost Price per product, and Inventory Valuation per product are correct. However, the total sum of the Inventory Valuation is not matching the expected result. I’ve manually checked in Excel, and the correct total should be $586M, but the KPI card is showing approximately $1.4B (rounded). I've also attached the Data Model view, and as mentioned, the KPI view is showing an incorrect total for Inventory Valuation — it should be $586M.

 
Hizqeel_0-1751520467519.png
 
 
 

Data Model.JPGMeasure USing.JPG

 

 

v-tsaipranay
Community Support
Community Support

Hi @Pmrs ,


After thoroughly reviewing the details you provided, I was able to reproduce the scenario, and it worked on my end. I have used it as sample data on my end and successfully implemented it.     

I am also including .pbix file for your better understanding, please have a look into it:

Thank you for using Microsoft Community Forum.

 

Hi @Pmrs ,

I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions.

 

Thank you.

maruthisp
Super User
Super User

Hi @Pmrs ,

As per the above problem description, I tried to implement a solution. Please find the below attached pbix file.
Total Target Calls.pbix

 

Please let me know if you have further questions.

If this reply helped solve your problem, please consider clicking "Accept as Solution" so others can benefit too. And if you found it useful, a quick "Kudos" is always appreciated, thanks! 

 

Best Regards, 

Maruthi 

LinkedIn - http://www.linkedin.com/in/maruthi-siva-prasad/ 

X            -  Maruthi Siva Prasad - (@MaruthiSP) / X

FBergamaschi
Solution Sage
Solution Sage

I requested access, please give it so we can help

 

Francesco Bergamaschi

 

Pmrs
Regular Visitor

Provided the access my end.

v-tsaipranay
Community Support
Community Support

Hi @Pmrs ,

Thank you for reaching out to the Microsoft Fabric Community. 

 

It seems that the link you shared is inaccessible on our end. Kindly provide the necessary access so we can look into it and take the required action.

vtsaipranay_0-1751371054810.png

 

Thank you.

 

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.