Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
Save the Date: QlikWorld Online, June 24-25, 2020. Free global virtual event for data integration and data analytic gurus. Register Today
Not applicable

New table with design value

Hi All !


I have the following table:

     

RouteStringTerminalNameRouteLineNumberOperationName=sum(Volume)
A-B-C-DA1LOAD200
A-B-C-DB2UNLOAD100
A-B-C-DB2LOAD300
A-B-C-DC3UNLOAD100
A-B-C-DC3LOAD150
A-B-C-DD4UNLOAD450


I need to create a new table with the calculation of Total Volume = Volume(where RouteLineNumber -1) - Volume(unload) + Volume(load)

The final result for example above should be:

    

RouteStringTerminalNameRouteLineNumberTotal Volume
A-B-C-DA1200
A-B-C-DB2400
A-B-C-DC3450
A-B-C-DD40

Does anybody have some ideas how to manage the calculus?

Thanks a lot in advance for help!

1 Solution

Accepted Solutions
Highlighted
MVP
MVP

Re: New table with design value

Try a chart with your three dimensions  (RouteString, TerminalName, RouteLineNumber) and as expression:

=Rangesum(    

     Above(TOTAL Sum({<OperationName = {'LOAD'}>} Volume),0,rowno(TOTAL)),

-   Above(TOTAL Sum({<OperationName = {'UNLOAD'}>} Volume),0,rowno(TOTAL)),

)

View solution in original post

2 Replies
Highlighted
MVP
MVP

Re: New table with design value

Try a chart with your three dimensions  (RouteString, TerminalName, RouteLineNumber) and as expression:

=Rangesum(    

     Above(TOTAL Sum({<OperationName = {'LOAD'}>} Volume),0,rowno(TOTAL)),

-   Above(TOTAL Sum({<OperationName = {'UNLOAD'}>} Volume),0,rowno(TOTAL)),

)

View solution in original post

Highlighted
Not applicable

Re: New table with design value

Thanks a lot!