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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
PrizzC15
Frequent Visitor

Count DOW and divide actual filter DOW

Hi 

I need help as below question:

PrizzC15_0-1670922100076.png

 

TIA

1 ACCEPTED SOLUTION
v-jianboli-msft
Community Support
Community Support

Hi @PrizzC15 ,

 

If the average aggregation could't work, please try:

 

Sales A =
var _a = SUM('Table'[Person A])
var _b = COUNT('Table'[DOW])
return DIVIDE(_a,_b)

Sales B =
var _a = SUM('Table'[Person A])
var _b = COUNT('Table'[DOW])
return DIVIDE(_a,_b)

 

 

Best Regards,

Jianbo Li

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

View solution in original post

7 REPLIES 7
v-jianboli-msft
Community Support
Community Support

Hi @PrizzC15 ,

 

If the average aggregation could't work, please try:

 

Sales A =
var _a = SUM('Table'[Person A])
var _b = COUNT('Table'[DOW])
return DIVIDE(_a,_b)

Sales B =
var _a = SUM('Table'[Person A])
var _b = COUNT('Table'[DOW])
return DIVIDE(_a,_b)

 

 

Best Regards,

Jianbo Li

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

v-jianboli-msft
Community Support
Community Support

Hi @PrizzC15 ,

 

Is that not the result you want? Or have I misunderstood?

vjianbolimsft_0-1671170630645.png

If I misunderstood, please provide me with more details about your table and your problem or share me with your pbix file after removing sensitive data.

 

Refer to:

How to provide sample data in the Power BI Forum

How to Get Your Question Answered Quickly

 

Best Regards,

Jianbo Li

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

v-jianboli-msft
Community Support
Community Support

Hi @PrizzC15 ,

 

Based on your description, I have created a simple sample:

vjianbolimsft_0-1671001849164.png

You can achieve this by using the average aggregation directly:

vjianbolimsft_1-1671002219677.png

Final output:

vjianbolimsft_2-1671002256752.png

Best Regards,

Jianbo Li

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

Hi, 

I trying to upload pbix but not able.

Herewith the details:

PrizzC15_0-1671176527882.png

 

Hope you can helps with this.

 

My result is difference:

PrizzC15_0-1671097255686.png

Based on Oct number DOW 

Mon, Sat & Sun divide 5

Tue, Wed, Thu, Fri divide 4

 

For example: Total of Sales for Person A in Oct 2022 by DOW

Fri 1004 / 4 = 251

Mon 943 / 5 = 188.6

 

Because each month it's difference DOW count

eg. in Jan 2022 (Mon, Sat & Sun x 5 days), in Mar 2022 (Tue, Wed & Thu x 5 days)...etc..

 

v-jianboli-msft
Community Support
Community Support

Hi @PrizzC15 

 

Sorry for that the picture you provided is not very clear. Can you share a clearer picture or share more details to help us clarify your scenario?

Please provide me with more details about your table and your problem or share me with your pbix file after removing sensitive data.

 

Refer to:

How to provide sample data in the Power BI Forum

How to Get Your Question Answered Quickly

 

Best Regards,

Jianbo Li

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

Thank you for your reply. I had replaced the picture. Feel free to clarify with me if any doubt of question.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

November Carousel

Fabric Community Update - November 2024

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

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.