Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
QlikView forum consolidation is complete. Labels are now required. LEARN ABOUT LABELS
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Issue in Previous() Function

Hi,

 

How to fill more than one null rows value using previous() function for example

available data

sno     date          value

1          1/1/2012     600

2          1/2/2012

3          1/3/2012    

4          1/4/2012     500

5          1/5/2012     400

6          1/6/2012    

7          1/7/2012    

8          1/8/2012     200

 

I used condition in script if(isnull(value),previous(value),value) as value but

it fill one row in value colum, requried result is valuef.

 

sno     date          value     valuef

1          1/1/2012     600     600

2          1/2/2012     600     600

3          1/3/2012               600

4          1/4/2012     500     500

5          1/5/2012     400     400

6          1/6/2012     400     400

7          1/7/2012                400

8          1/8/2012     200     200

1 Solution

Accepted Solutions
rajni_batra
Specialist
Specialist

19 Replies
thomas_skariah
Creator III
Creator III

Hi,

I have created a sample application similar to your scenario,go through it.

Hope this will work for you.

Regards,

Tom

whiteline
Master II
Master II

HI

You shoud use Peek() instead previous().

The first one works with the destination table while the second with te source.

In the source you have  null in second row so you get null in third row.

Not applicable

Hi Tim,

Can you attach the sample excel file,just to know the purpose of counter field.

Thanks in advance.

Not applicable

Thanks for reply but my result still same, plz also let me know how i attach my files.

Regards,

Zain.

rajni_batra
Specialist
Specialist

why dont u fill these values in traformation step when loading the data.

see the screenshot

hope to help

Not applicable

Dear i have exchange rate qvd and i want to attach for your understanding, its clear to you what i want to do.

Regards,

Zain

rajni_batra
Specialist
Specialist

then do attach that qvd so that could help u more accurately

Not applicable

i havnt found attachment option, plz guide me where attachment option, kindly attached snap its easy to me,

Regards,

Zain.

rajni_batra
Specialist
Specialist

when u choose to reply see right side of the window 'use advance editor'

there is an option below  to upload .

from there u can upload ur QVD.