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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
ankitbisht01
Creator
Creator

Cumulative values

Hi, i have a sample inline table :

A:

LOAD * INLINE [

    Product , Revenue

    A, 5000

    B, 10000

    C, 15000

    D, 7000

    E, 4500

    F, 5600

    G, 7000

    H, 6000

];

i wan' t to create a third column it shows cumulative values from "Revenue"

what can i use , i have little idea to use rangesum() and above function. but nt able to get output.

Thankx

1 Solution

Accepted Solutions
antoniotiman
Master III
Master III

RangeSum(Peek(Revenue),Revenue) as ProgressiveRevenue

View solution in original post

5 Replies
antoniotiman
Master III
Master III

RangeSum(Peek(Revenue),Revenue) as ProgressiveRevenue

qlikmsg4u
Specialist
Specialist

Hi ankit,

Please try this

Load *,RangeSum(Revenue,Peek('Cum')) as Cum;

LOAD * INLINE [

    Product , Revenue

    A, 5000

    B, 10000

    C, 15000

    D, 7000

    E, 4500

    F, 5600

    G, 7000

    H, 6000

];

Chanty4u
MVP
MVP

Hi,,

PFA

hope ur requirmnt

Thank you

Suresh

jagan
Partner - Champion III
Partner - Champion III

Hi Ankit,

Try this script below

A:

LOAD *,

RangeSum(Peek(CumRevenue), Revenue) AS CumRevenue

INLINE [

    Product , Revenue

    A, 5000

    B, 10000

    C, 15000

    D, 7000

    E, 4500

    F, 5600

    G, 7000

    H, 6000

];

Regards,

Jagan.

ankitbisht01
Creator
Creator
Author

Thank You for instant replies