Hello. I have an Excel sheet containing montly budget. The budget value is set on the first of every month. All the other dates have NULL budget value. I'm trying to fill the nulls with previous non-null value using Peek, but i'm struggling.
My goal is to compare the daily Net amount with a recalculated daily budget, but as i'm excluding weekends from my chart I lose the budget from the months where the first of the month accurs on a sat or sunday.
I've also tried other variations of Peek that i've found online but with the same result.
This is my load script for the budget:
CrossTableLOAD:
CrossTable (Datum, Budget)
LOAD *
FROM [lib://Qlikdata(Glasgruppen) (ad_ext_kons)/Budget2.xlsx]
(ooxml, embedded labels, table is [Blad1]);
join (Data)
Load
Date(trim(Datum),'YYYY-MM-DD') AS [Date of Entry],
If(IsNull(Budget), Peek(New_Budget), Budget) as New_Budget,
[Klient] as [%awclient]
Resident CrossTableLOAD;
Drop Table CrossTableLOAD;
This is my result:
Any suggestions?
/Andreas