Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
kavita25
Partner - Specialist
Partner - Specialist

Please help me with the carry forward logic

Hi Everyone,

Please help me with carry forward logic. I have already tried the solution provided in community.

I have attached sample data. Please look into the data.

As you can see in the above snapshot, the "stock amount"  is not repeated. My requirement is to repeat the "Stock Amount" as it doesn't get the new value.

Thanks in advance

Regards,

Kavita

8 Replies
crusader_
Partner - Specialist
Partner - Specialist

Hi,

Can you provide expected result in excel or screenshot?

It will help us better understand your requirements.

Regards,

Andrei Kaliahin

robert_mika
Master III
Master III

Can you explain this a little bit more?

What do you expect to get?

kavita25
Partner - Specialist
Partner - Specialist
Author

My requirement is to get the repeated value till the new value is not updated.

In the snapshot:

Part    Branch        Date        Amount

1          ABC          31/03/2013  100

1          ABC          20/04/2013    200

The output should be like the amount "100" should be repeated from 31/03/2013 till 19/04/2013

robert_mika
Master III
Master III

Repeated where?

Your data you just posted does not match with your Excel file.

sushil353
Master II
Master II

Hi,

Are you looking to generate data between dates ?

crusader_
Partner - Specialist
Partner - Specialist

Oh... in this case you can use

LOAD

     ID

     , previous(Date)+IterNo()

     , Amount

While Date>previous(Date)

OR better way to organize Slowly Changing Dimesnions Type 2:

Part Branch Date_start Date_End     Amount

1     ABC     31/03/2013 19/04/2013     100

And using IntervalMatch make intervals.

TO learn more you can read http://community.qlik.com/blogs/qlikviewdesignblog/2013/02/12/reference-dates

and http://community.qlik.com/blogs/qlikviewdesignblog/2013/04/04/intervalmatch

Regards,

Andrei Kaliahin

kavita25
Partner - Specialist
Partner - Specialist
Author

In Pivot Table

Expected output:

Anonymous
Not applicable

Hello,

Check the attachment.

HTH