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
Anonymous
Not applicable

How to build a dashboard showing the data which overs a limit?

Hi everyone,

 

I want to build a dashboard, which will only shows the data when the working hour over limit weekly.

 

like the following:

There are buttons to click to see the related data. (It's just a draft, I'm welcome for any other suggestion)

DraftDraft

 

And I got the following two Excel files for data source.

(1)

pikki_1-1615190497546.png

 

(2)

pikki_2-1615190557046.png

 

Is it possible to build a dashboard like the draft with the two Excel file I got? 

Or any methods other than using Power BI?

Thanks a lot!

 

2 ACCEPTED SOLUTIONS
v-yuaj-msft
Community Support
Community Support

Hi @Anonymous ,

 

Based on your description, I create a sample test table from your data. Here is my test table.

v-yuaj-msft_0-1615354743673.png

You can do some steps as follows.

1. create a column to calculate the working hours.

2. create a calendar table to  prepare for filters.

v-yuaj-msft_1-1615354826121.png

3. create a measure to summarize the weekly working hours. You can test it in a matrix visual.

v-yuaj-msft_2-1615355067381.png

4.create a slicer using "calendar[Date]" and go to settings----"general"----"orientation"-----choose "Horizontal"

 

v-yuaj-msft_0-1615355277018.png

v-yuaj-msft_1-1615355338331.png

5. create a measure(">=20") and a table visual, then drag it to the filter of this visual and select "=1"

Measure = 

var x1=SELECTEDVALUE('calendar'[Date])

return

IF([Sum of weekly working hour]>=20&&MAX('Test'[Date])>=x1-4&&MAX('Test'[Date])<=x1,1,0)

v-yuaj-msft_2-1615355396816.png

Result:

031001.gif

Of course, you can create a new measure which is similar to the above one to filter "working hours>=30".

031002.gif

Hope that's what you were looking for.

Best Regards,

Yuna

 

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

@Anonymous  See what you think of the attached pbix file (below signature). It gives option to select limit (20, 30 hrs) and Week End date to filter the table.

 

For updating the data, you can use Get Data > From Folder and just keep appending the latest Excel file into the pbix.


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

View solution in original post

7 REPLIES 7
v-yuaj-msft
Community Support
Community Support

Hi @Anonymous ,

 

Could you tell me if your problem has been solved? If it is, kindly Accept it as the solution. More people will benefit from it.😊

 

Best Regards,

Yuna

v-yuaj-msft
Community Support
Community Support

Hi @Anonymous ,

 

Based on your description, I create a sample test table from your data. Here is my test table.

v-yuaj-msft_0-1615354743673.png

You can do some steps as follows.

1. create a column to calculate the working hours.

2. create a calendar table to  prepare for filters.

v-yuaj-msft_1-1615354826121.png

3. create a measure to summarize the weekly working hours. You can test it in a matrix visual.

v-yuaj-msft_2-1615355067381.png

4.create a slicer using "calendar[Date]" and go to settings----"general"----"orientation"-----choose "Horizontal"

 

v-yuaj-msft_0-1615355277018.png

v-yuaj-msft_1-1615355338331.png

5. create a measure(">=20") and a table visual, then drag it to the filter of this visual and select "=1"

Measure = 

var x1=SELECTEDVALUE('calendar'[Date])

return

IF([Sum of weekly working hour]>=20&&MAX('Test'[Date])>=x1-4&&MAX('Test'[Date])<=x1,1,0)

v-yuaj-msft_2-1615355396816.png

Result:

031001.gif

Of course, you can create a new measure which is similar to the above one to filter "working hours>=30".

031002.gif

Hope that's what you were looking for.

Best Regards,

Yuna

 

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

 

 

 

Anonymous
Not applicable

Thank you so much for your detailed answer! It's also very useful and will make reference to it. Thank you!!

AllisonKennedy
Super User
Super User

@Anonymous  It looks like you have already done some calculations in Excel. These two files look like the same info in two formats. Which is the raw data? It will be best to use that raw format as the source for Power BI, and do all the calculations and transformations in Power BI. 

 

Also, how does this update from week to week? Ideally you want to have those selections for date range dynamically update so you don't need to rebuild the report each week. 

 

Please share a sample file (via OneDrive or other service) of the orginal data either as export direct from your database or in the format it is entered into Excel. 

 

From there we can help you better with your required dashboard/report setup.

 

Please @ mention me so I don't lose this thread. 


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

Anonymous
Not applicable

@AllisonKennedy 

Thank you so much for your detailed reply!

Here is the raw file:

https://1drv.ms/x/s!AtRpvjeBYBZ0lX3ZL5eQh_54pRh_

 

For update data, I am thinking to use an excel file to store all the data and it will be linked to Power BI, afterward any new data would be copied into this file, as only around 30-40 fileds of new data will be generated each time.

 

@Anonymous  See what you think of the attached pbix file (below signature). It gives option to select limit (20, 30 hrs) and Week End date to filter the table.

 

For updating the data, you can use Get Data > From Folder and just keep appending the latest Excel file into the pbix.


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

Anonymous
Not applicable

This is what I want! Thank you so much and much!!

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.