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

Announcements
Posting on Qlik Community is temporarily paused for some users. Thank you for patience and we'll update you soon!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

sum (expression)

sum(interval(INTime-VLateTime,'hh:mm'))

it shows error in calculation

Labels (1)
13 Replies
Anonymous
Not applicable
Author

The person ID is one of the dimsnsions of the chart.  Your expression without sum

=Interval (INTime-VLateTime,'hh:mm')

returns result per line, person / date.

My expression with sum and aggr

=interval(aggr(sum(INTime-VLateTime),ID), 'hh:mm')

returns result per person for all dates  Use what you consider is more appropriate for your purpose.

Regards,

Michael

Anonymous
Not applicable
Author

Modify a little:

=

interval(aggr(sum(INTime-VLateTime),ID,DEPARTMENT), 'hh:mm') 

You also maybe need a different presentation, not a table like this - but thisexpression should work in any case.

CELAMBARASAN
Partner - Champion
Partner - Champion

For this you need to calculate this inside the script itself. Considering the performance and ease of use.

PresentDetails:

LOAD ID,

Date(Date#(Date, 'DD/MM/YYYY')) as PresentDate,

    Time( IN) as INTime ,

     Interval(INTime-$(VLateTime),'hh:mm') AS LateHours,

     OUT

FROM

(ooxml, embedded labels, table is Sheet1);

Anonymous
Not applicable
Author

That's correct, if create it as a field in the script, front end is very easy.