Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
Hello,
I have a 2 part question manipulating my Time values.
First question; I'd like to sum my Event entries I have for each hour and plot them on line graph.
I have created a custom column in my Power Queury Editor that separates the time from the date but I'm not seeing an option to sum the entries on a per hour basis when I set the column as the Axis.
I am able to create another column that separates the Hour and plot these values but my x axis is not what I'm looking for.
Second question; what is the most effficent way to create another column that will assign either the Time or Hour column according to these ranges;
12:00:00 AM to 5:59:00 AM = "ON"
6:00:00 AM to 1:59:00 PM = "AM"
2:00:00 PM to 10:00:00 PM = "PM"
10:01:00 PM to 11:59:00 PM = "ON"
Here is a sample of the data in my Queury Editor.
Thanks in advance for your help!
Solved! Go to Solution.
@Anonymous Try adding a new column for 'start of hour' to get the x-axis you're looking for in your first question:
For your second question you can add a new Conditional Column in Power Query:
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 Try adding a new column for 'start of hour' to get the x-axis you're looking for in your first question:
For your second question you can add a new Conditional Column in Power Query:
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
Thank you so much! This worked exactly as I was hoping...and more straight forward than I was visualizing.
Hi @Anonymous
To answer your second question: Add a conditional column in power query
your first question is not clear and espacially the first Graph Y Axis = Count of Time and X Axis = Time !!
Can you share a dummy Pbix?
Regards
Amine Jerbi
If I answered your question, please mark this thread as accepted
and you can follow me on
My Website, LinkedIn and Facebook
User | Count |
---|---|
141 | |
113 | |
104 | |
77 | |
64 |
User | Count |
---|---|
135 | |
123 | |
101 | |
71 | |
61 |