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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
KvR
Regular Visitor

Calculate/sum up values from Weekend-days to next monday after weekend

Hello, I could not find any topics with this particular problem, maybe I did not seach well enough.

 

I have this dataset with total values on dates (like total sales per day), and the total values of the weekend-days (saturday and sunday) needs to be added up to the total values on the next monday. We want to calculate our results per day, but because in the weekends the opartions is only at 20%, it gives not a good average overall.

 

This is the dataset in Power BI:

Dataset presented in Power BIDataset presented in Power BI

This is how we calculate it very primitively in Excel (same dataset):

Values copied from pivot from same datasetValues copied from pivot from same dataset

This is the matrix that is coming from the calculation in Power BI:

Values in matrix (pivot) in Power BI with lesser values on the weekend-daysValues in matrix (pivot) in Power BI with lesser values on the weekend-days

It would be ideal if there is some kind of time-intelligence-like measure to handle this. The values will later be used in a KPI dashboard. So the calculation as presented on the screenshot is not the endproduct that is needed.

 

Anyone idea's in which direction i need to search this. I did some tries on DAX and Time intelligence to tackle this, but I am not getting any closer. Maybe it is not possible with a measure of calculated column, and do I need to think about a datawarehouse-like structur (puting in an extra table).

 

Thanks in advance, KvR

1 ACCEPTED SOLUTION
Greg_Deckler
Super User
Super User

I would think that you could get there using WEEKDAY function and something like my Time Intelligence the Hard Way Quick Measure.

https://community.powerbi.com/t5/Quick-Measures-Gallery/Time-Intelligence-quot-The-Hard-Way-quot-TIT...


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

4 REPLIES 4
KvR
Regular Visitor

We solved it with building a function within SQL Management studio, so not in Power BI directly. Nevertheless, thanks for your help.

v-jiascu-msft
Employee
Employee

Hi @KvR ,

 

Could you please mark the proper answers as solutions?

 

 

Best Regards,

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

I would think that you could get there using WEEKDAY function and something like my Time Intelligence the Hard Way Quick Measure.

https://community.powerbi.com/t5/Quick-Measures-Gallery/Time-Intelligence-quot-The-Hard-Way-quot-TIT...


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

I will look at it later today, thanks 🙂

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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