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

Roll up for BoM in straight table

Hello Community, 

I try to make a sum/multiplication Roll up for Quantities (numeric) over a with hierarchy created Path. 

my table looks like 

Path                                                 | Quantities           What I want to achive(TotalQuantites)

A                                                       | 1                               1

A;B                                                   | 2                               2  ( 1*2)

A;C                                                   | 5                               5  ( 1*5)

A;D                                                   | 1                               1 (1*1)

A;B;E                                               | 3                                6 ( 1*2*3)

A;B;F                                               | 5                                10 (1*2*5)

And so on with far more complex lists.  

I have already created the TotalQuantites field in script. But duo to new requirements I need to calculate it in UI. 

Maybe something like "if(left(Path, len(Path)-2) = above(Path),    RangeSum(Above(sum(Quantities)),0,rowno()))"

I guess I need a combination of RangeSum, above, wildmatch to compare current line Path with above(?) matching Path.

@hic 

got some nice explanation to handle BoM and create a TotalQty field in script but not in UI. 

Maybe you guys have some nice input for me. 

 

Thank you !

 

Labels (1)
1 Reply
William2
Contributor III
Contributor III
Author

@sunny_talwar Any suggestion ? Some of your posts goes in this direction