cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
RGI Regular Visitor
Regular Visitor

Average of Time column

I have a few Time columns in MSSQL.

I'm hoping to display these with their AVERAGE in a table.

Screen Shot 2018-07-23 at 11.47.11.png

The actual times on the rows are correctly displayed, but no option to display a final total (AVERAGE).

Is this possible?

Currently I'm using Direct Query, but could easily switch to Import.

I can, if it makes it easier, store the times as seconds (Integer) in MSSQL instead of Time.

 

2 ACCEPTED SOLUTIONS

Accepted Solutions
Highlighted
Super User
Super User

Re: Average of Time column

See if this article helps:

 

https://community.powerbi.com/t5/Community-Blog/Aggregating-Duration-Time/ba-p/22486

 

 


I have book! Learn Power BI from Packt


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

Proud to be a Datanaut!

View solution in original post

Community Support Team
Community Support Team

Re: Average of Time column

Hi @RGI,

 

It seems that you want to calculate the average of your time, you could have a good reference of this similar thread.

 

If you still need help, please share your data sample and your expected output, so that we can help further investigate on it?

 

Best  Regards,

Cherry

Community Support Team _ Cherry Gao
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

3 REPLIES 3
Highlighted
Super User
Super User

Re: Average of Time column

See if this article helps:

 

https://community.powerbi.com/t5/Community-Blog/Aggregating-Duration-Time/ba-p/22486

 

 


I have book! Learn Power BI from Packt


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

Proud to be a Datanaut!

View solution in original post

Community Support Team
Community Support Team

Re: Average of Time column

Hi @RGI,

 

It seems that you want to calculate the average of your time, you could have a good reference of this similar thread.

 

If you still need help, please share your data sample and your expected output, so that we can help further investigate on it?

 

Best  Regards,

Cherry

Community Support Team _ Cherry Gao
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

RGI Regular Visitor
Regular Visitor

Re: Average of Time column

My solution so far:

 

1) I changed the [Time] column in the database to [Int] (seconds).

2) I implemented a new measure as

 

Average Time to Empty Bin = TIME(INT(AVERAGE(Wave[Average Seconds to Empty Bin])/3600),INT(MOD(AVERAGE(Wave[Average Seconds to Empty Bin]),3600)/60),0)

 

This now shows the correct data in the column and a nice average in the total row.

 

However, as I've posted in this thread my slicers have stopped working.

Helpful resources

Announcements
Can You Solve These Challenge

Challenge: Can You Solve These?

Find out how to participate in the first Power BI 'Can You Solve These?' challenge.

Community News & Announcements

Community News & Announcements

Get your latest community news and announcements.

Virtual Launch Event

Microsoft Business Applications October Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

Community Kudopalooza

Win Power BI Swag with Community Kudopalooza!

Each week, complete activities and be qualified in the drawing for cool Power BI Swag.

Users Online
Currently online: 6 members 1,003 guests
Please welcome our newest community members: