Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
stantrolav
Partner - Creator II
Partner - Creator II

Load value in previous ROW if Null

Hi!

In Attachment you'll find example for work. Sheet 1 is loaded data. Sheet 2 is what I need to make in QVD table.

QUESTION:

How can I load data to spec fields in  row with data from previous row if there is no data for date?

SHEET 1                                          

AgrDateVal1Val2
4774L14.02.20140,07920726910 729,01
4774L28.02.20140,07920726728 138,41
4774L14.03.20140,07920726733 915,85
4798L10.02.20140,0578173 005,45
4798L28.02.20140,0578162 919,76
4798L11.03.20140,0578164 417,85

SHEET 2

AgrDateVal1Val2
4774L14.02.20140,07920726910 729,01
4774L15.02.20140,07920727910 729,01
4774L16.02.20140,07920728910 729,01
4774L17.02.20140,07920729910 729,01
4774L18.02.20140,07920730910 729,01
4774L19.02.20140,07920731910 729,01
4774L20.02.20140,07920732910 729,01
4774L21.02.20140,07920733910729,01
4774L22.02.20140,07920734910729,01
4774L23.02.20140,07920735910  729,01
4774L24.02.20140,07920736910 729,01
4774L25.02.20140,07920737910  729,01
4774L26.02.20140,07920738910  729,01
4774L27.02.20140,07920739910  729,01
4774L28.02.20140,07920740728  138,41
4774L01.03.20140,07920741728  138,41
4774L02.03.20140,07920742728  138,41
4774L03.03.20140,07920743728  138,41
4774L04.03.20140,07920744728  138,41
4774L05.03.20140,07920745728  138,41
4774L06.03.20140,07920746728  138,41
4774L07.03.20140,07920747728  138,41
4774L08.03.20140,07920748728  138,41
4774L09.03.20140,07920749728  138,41
4774L10.03.20140,07920750728  138,41
4774L11.03.20140,07920751728  138,41
4774L12.03.20140,07920752728  138,41
4774L13.03.20140,07920753728  138,41
4774L14.03.20140,07920726733  915,85
4798L10.02.20140,0578173  005,45
4798L11.02.20140,0578173  005,45
4798L12.02.20140,0578173 005,45
4798L13.02.20140,0578173  005,45
4798L14.02.20140,0578173  005,45
4798L15.02.20140,0578173  005,45
4798L16.02.20140,0578173  005,45
4798L17.02.20140,0578173  005,45
4798L18.02.20140,0578173  005,45
4798L19.02.20140,0578173  005,45
4798L20.02.20140,0578173  005,45
4798L21.02.20140,0578173  005,45
4798L22.02.20140,0578173  005,45
4798L23.02.20140,0578173  005,45
4798L24.02.20140,0578173  005,45
4798L25.02.20140,0578173  005,45
4798L26.02.20140,0578173  005,45
4798L27.02.20140,0578173  005,45
4798L28.02.20140,0578162919,8
4798L01.03.20140,0578162919,8
4798L02.03.20140,0578162919,8
4798L03.03.20140,0578162919,8
4798L04.03.20140,0578162919,8
4798L05.03.20140,0578162919,8
4798L06.03.20140,0578162919,8
4798L07.03.20140,0578162919,8
4798L08.03.20140,0578162919,8
4798L09.03.20140,0578162919,8
4798L10.03.20140,0578162919,8
4798L11.03.20140,0578164 417,85
4798L12.03.20140,0578164  417,85
4798L13.03.20140,0578164  417,85
4798L14.03.20140,0578164  417,85
3 Replies
stantrolav
Partner - Creator II
Partner - Creator II
Author

Here is script of how to make every Date in date interval.


LOAD
Date as Date1
Resident SHEET1
Order by Date_1c_UCL;

LET varMinDate = Num(Peek ('Date1',0,'SortOrder'));
LET varMaxDate = Num(Peek('Date1',-1,'SortOrder'));
LET varToday = Num(Today());

//************TempCalendar***********
TempCalendar:
LOAD
$(varMinDate) + rowno() - 1 AS DateNumber,
date ($(varMinDate) + rowno() - 1) AS TempDate
AUTOGENERATE $(varMaxDate) - $(varMinDate) + 1;

//*************Master Calendar************
Calendar:
LOAD
TempDate AS Date,
Resident TempCalendar
Order by TempDate ASC;

Anonymous
Not applicable

Stanislav,

See attached (similar question long ago), hope it helps.

Gysbert_Wassenaar

Please don't create more than one discussion for the same topic: http://community.qlik.com/thread/104342


talk is cheap, supply exceeds demand