Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Roveqz
Contributor
Contributor

Daily Average of Houly Sum of Data

Hi! Im a newbie to QS. May data is composed of the following Columns below.

Location YEAR YEAR2 MONTH WEEK DAY DATE HOUR RESOURCE_ID FUEL_TYPE TYPE PARTICIPANT GRID MAX_OFFER SCHEDULE SUPPLY

 

What formula should I use to display the Daily Average of Sum of SCHEDULE... I'm using the formula

Avg(Sum(DATE,HOUR) SCHEDULE)

it says nested aggregation not supported...

 

Would love to hear from you. Thanks in advance.

Labels (1)
1 Reply
hic
Former Employee
Former Employee

Try

Avg(Aggr(Sum(SCHEDULE),DATE,HOUR) )

The Aggr() is necessary for all nested aggregations. Here, it will calculate the Sum(SCHEDULE) for each combination of DATE and HOUR, and then calculate the average of the result.

If you want to display this per Date, you should create a chart (pivot table, bar chart, etc.) with Date as dimension and the above expression as measure.