Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Connect 2026! Turn data into bold moves, April 13 -15: Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to calculate week value from hourly counter value?

Dear qlikviewers,

I'm developing an energy management dashboard where the customer can view the gasconsumption per hour, day,week,month.

The datasource is an excelsheets with data from the gascounters. The gas counter value is registered every hour of the day. The excelsheet contains data for a week.

I've added the excelsheet in the attachement. It can be found in the directory 'data'.

because it is a gascounter, I can calculate the actual gasconsumption for a day as follows:

- I have to get value from the last hour of the day minus the value from the first hour of the day.

How can I accomplish a calculation where I can get the gasconsumption from my gascounter values for:

- Day

- Week

- Month

ps ;

I already have a construction by doing this in a expression:

Num(Max([Measured average value])) - Num(Min([Measured average value]))

However, with this i cant add set analysis expressions and I want to have it precalculated in my script, because it will be used frequently.

When I add the above expression, my script gets an error.

0 Replies