Discussion Board for collaboration related to Creating Analytics for QlikView.
Suppose I have a tbale with dates..
I want a table with following columns...
I want Previous and next record of each rows.
Thanks in advance...
I think you can use the interrecord functions: above and below:
as expressions for Previous Date and Next Date with dimension Date.
I have to use those Previous Date and Next Date fields in Some calculations.
So I need those fields only in script part. I also used Previous and peek functions.
But value I am getting is not right.
Yes right you need to use the Above and Below fuctions for the date view for the Previous Date and Next Date put Above(Date) , Below(Date).
See the attached sample for clearing your problems.
If you want to create that table in script, you might use something like:
Left Join Load *,
peek(Date) as NextDate
resident Dates order by Date desc;
peek(Date) as PreviousDate
resident Dates order by Date ASC;
Where Dates is your calendar table with field Date.