Showing results for 
Search instead for 
Did you mean: 
Not applicable

Sum, divide and average of value field from two tables with no relationship



I have two tables having similar column names only difference is the value column which I want to calculate.




There is no relationship between the two tables, it is many to many. I am trying to first sum the values column from both the tables and then divide the sum values to create a measure, but when I try to check with the columns the divide measure gives incorrect values.




I further want to create another measure to get the average of the divide measure till the week where value is not zero and store it in another measure. Can you suggest where I am going wrong.

Community Support
Community Support

Hi, @Anonymous 


May I ask if your problem has been solved? Is the above post helpful to you?

Is there an error in the percentages? What is the formula for your measure?

Could you please consdier sharing more details about it or a simple sample file without any sesentive information for further discussion?




Best Regards,
Community Support Team _ Zeon Zheng

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Super User
Super User

@Anonymous , You should join these two tbale on common dimensions like time and store ,and then you can analyze

divide(Sum(Table1[Col]), Sum(Table2[Col]) ) should work


if need a simple avg


AverageX(values('Date'[week]), Calculate( divide(Sum(Table1[Col]), Sum(Table2[Col]) ) ))

Did I answer your question? Mark my post as a solution! Appreciate your Kudos!! !!
Dashboard of My Blogs !! Connect on Linkedin
Want To Learn Power BI
Learn Power BI Beginners !! Advance Power BI Concepts !! Power BI For Tableau User !! Learn Power BI in Hindi !!
Proud to be a Super User!
!! Subscribe to my youtube Channel !!
Not applicable

Thanks @amitchandak , Should I create a date table and link the weekdays to it? Or should I add a time column for both the tables and join them together?

Helpful resources

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

charticulator_carousel_with_text (1).png

Charticulator Design Challenge

Put your data visualization and design skills to the test! This exciting challenge is happening now through May 31st!

Power BI Dev Camp Session 22 768x460.jpg

Check it out!

Mark your calendars and join us on Thursday, May 26 at 11a PDT for a great session with Ted Pattison!

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.