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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
2023Lee
Frequent Visitor

dashboard visual - running or shutdown status of a equipment

Hi 

I met a problem that I don't how to display the operation status of equipment with a line chart.😭

The concept template and raw data are like this:

We have the Down and Start time data of the equipment, just want to monitor it's actual operation status showed as 0 &1.

Anyone have some solutions or ideas? 

Picture1.png

Down timeUp time
7/16/2023 9:00:00 PM7/21/2023 11:30:00 PM
7/28/2023 11:05:00 PM7/31/2023 11:59:00 PM
8/1/2023 12:00:00 AM8/1/2023 3:00:00 AM
8/2/2023 3:00:00 AM8/11/2023 4:00:00 AM
8/12/2023 5:00:00 AM8/15/2023 11:00:00 PM
8/18/2023 3:30:00 AM8/25/2023 12:00:00 AM

 

1 ACCEPTED SOLUTION
dk_dk
Super User
Super User

Hi @2023Lee ,

Try the following:

In Query editor, create this query: 

let
    Source = Source,
    #"Unpivoted Columns" = Table.UnpivotOtherColumns(Source, {}, "Attribute", "Value"),
    #"Added Custom" = Table.AddColumn(#"Unpivoted Columns", "Running Flag", each if [Attribute] = "Down time" then 0 else 1),
    #"Changed Type" = Table.TransformColumnTypes(#"Added Custom",{{"Running Flag", Int64.Type}})
in
    #"Changed Type"

where Source is the table with up and downtimes, with the two columns in proper date/time format.

 

Then you can create the following line chart:

dk_dk_0-1698309835907.png

You achieve this look by changing Line Type to Step in the Visual settings for the line chart.
One small issue is that the step will change always at the halfway point between the two specified times, so it will show the chart incorrectly. I found others have similar issue in this thread where the proposed solution is to use Power KPI 2.0.0 custom visual instead.

I hope this helps.






Did I answer your question? Mark my post as a solution!

Proud to be a Super User!





View solution in original post

2 REPLIES 2
dk_dk
Super User
Super User

Hi @2023Lee ,

Try the following:

In Query editor, create this query: 

let
    Source = Source,
    #"Unpivoted Columns" = Table.UnpivotOtherColumns(Source, {}, "Attribute", "Value"),
    #"Added Custom" = Table.AddColumn(#"Unpivoted Columns", "Running Flag", each if [Attribute] = "Down time" then 0 else 1),
    #"Changed Type" = Table.TransformColumnTypes(#"Added Custom",{{"Running Flag", Int64.Type}})
in
    #"Changed Type"

where Source is the table with up and downtimes, with the two columns in proper date/time format.

 

Then you can create the following line chart:

dk_dk_0-1698309835907.png

You achieve this look by changing Line Type to Step in the Visual settings for the line chart.
One small issue is that the step will change always at the halfway point between the two specified times, so it will show the chart incorrectly. I found others have similar issue in this thread where the proposed solution is to use Power KPI 2.0.0 custom visual instead.

I hope this helps.






Did I answer your question? Mark my post as a solution!

Proud to be a Super User!





2023Lee
Frequent Visitor

Hi @dk_dk 

Thanks for your solution, I used the query and Power KPI 2.0.0 for the visiualization, it seems can solve this problems. I can choose the Step-after of this line chart interpolation, which will not change in the halfway point.

Many thanks for your kindness!😀

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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.

Top Solution Authors
Top Kudoed Authors