Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
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
Agr | Date | Val1 | Val2 |
4774L | 14.02.2014 | 0,07920726 | 910 729,01 |
4774L | 28.02.2014 | 0,07920726 | 728 138,41 |
4774L | 14.03.2014 | 0,07920726 | 733 915,85 |
4798L | 10.02.2014 | 0,0578 | 173 005,45 |
4798L | 28.02.2014 | 0,0578 | 162 919,76 |
4798L | 11.03.2014 | 0,0578 | 164 417,85 |
SHEET 2
Agr | Date | Val1 | Val2 |
4774L | 14.02.2014 | 0,07920726 | 910 729,01 |
4774L | 15.02.2014 | 0,07920727 | 910 729,01 |
4774L | 16.02.2014 | 0,07920728 | 910 729,01 |
4774L | 17.02.2014 | 0,07920729 | 910 729,01 |
4774L | 18.02.2014 | 0,07920730 | 910 729,01 |
4774L | 19.02.2014 | 0,07920731 | 910 729,01 |
4774L | 20.02.2014 | 0,07920732 | 910 729,01 |
4774L | 21.02.2014 | 0,07920733 | 910729,01 |
4774L | 22.02.2014 | 0,07920734 | 910729,01 |
4774L | 23.02.2014 | 0,07920735 | 910 729,01 |
4774L | 24.02.2014 | 0,07920736 | 910 729,01 |
4774L | 25.02.2014 | 0,07920737 | 910 729,01 |
4774L | 26.02.2014 | 0,07920738 | 910 729,01 |
4774L | 27.02.2014 | 0,07920739 | 910 729,01 |
4774L | 28.02.2014 | 0,07920740 | 728 138,41 |
4774L | 01.03.2014 | 0,07920741 | 728 138,41 |
4774L | 02.03.2014 | 0,07920742 | 728 138,41 |
4774L | 03.03.2014 | 0,07920743 | 728 138,41 |
4774L | 04.03.2014 | 0,07920744 | 728 138,41 |
4774L | 05.03.2014 | 0,07920745 | 728 138,41 |
4774L | 06.03.2014 | 0,07920746 | 728 138,41 |
4774L | 07.03.2014 | 0,07920747 | 728 138,41 |
4774L | 08.03.2014 | 0,07920748 | 728 138,41 |
4774L | 09.03.2014 | 0,07920749 | 728 138,41 |
4774L | 10.03.2014 | 0,07920750 | 728 138,41 |
4774L | 11.03.2014 | 0,07920751 | 728 138,41 |
4774L | 12.03.2014 | 0,07920752 | 728 138,41 |
4774L | 13.03.2014 | 0,07920753 | 728 138,41 |
4774L | 14.03.2014 | 0,07920726 | 733 915,85 |
4798L | 10.02.2014 | 0,0578 | 173 005,45 |
4798L | 11.02.2014 | 0,0578 | 173 005,45 |
4798L | 12.02.2014 | 0,0578 | 173 005,45 |
4798L | 13.02.2014 | 0,0578 | 173 005,45 |
4798L | 14.02.2014 | 0,0578 | 173 005,45 |
4798L | 15.02.2014 | 0,0578 | 173 005,45 |
4798L | 16.02.2014 | 0,0578 | 173 005,45 |
4798L | 17.02.2014 | 0,0578 | 173 005,45 |
4798L | 18.02.2014 | 0,0578 | 173 005,45 |
4798L | 19.02.2014 | 0,0578 | 173 005,45 |
4798L | 20.02.2014 | 0,0578 | 173 005,45 |
4798L | 21.02.2014 | 0,0578 | 173 005,45 |
4798L | 22.02.2014 | 0,0578 | 173 005,45 |
4798L | 23.02.2014 | 0,0578 | 173 005,45 |
4798L | 24.02.2014 | 0,0578 | 173 005,45 |
4798L | 25.02.2014 | 0,0578 | 173 005,45 |
4798L | 26.02.2014 | 0,0578 | 173 005,45 |
4798L | 27.02.2014 | 0,0578 | 173 005,45 |
4798L | 28.02.2014 | 0,0578 | 162919,8 |
4798L | 01.03.2014 | 0,0578 | 162919,8 |
4798L | 02.03.2014 | 0,0578 | 162919,8 |
4798L | 03.03.2014 | 0,0578 | 162919,8 |
4798L | 04.03.2014 | 0,0578 | 162919,8 |
4798L | 05.03.2014 | 0,0578 | 162919,8 |
4798L | 06.03.2014 | 0,0578 | 162919,8 |
4798L | 07.03.2014 | 0,0578 | 162919,8 |
4798L | 08.03.2014 | 0,0578 | 162919,8 |
4798L | 09.03.2014 | 0,0578 | 162919,8 |
4798L | 10.03.2014 | 0,0578 | 162919,8 |
4798L | 11.03.2014 | 0,0578 | 164 417,85 |
4798L | 12.03.2014 | 0,0578 | 164 417,85 |
4798L | 13.03.2014 | 0,0578 | 164 417,85 |
4798L | 14.03.2014 | 0,0578 | 164 417,85 |
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;
Stanislav,
See attached (similar question long ago), hope it helps.
Please don't create more than one discussion for the same topic: http://community.qlik.com/thread/104342