Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
basically I am attempting to create a incremental load script for a app I am working on and im trying to make a load function to incrementally update without a modified date(not available in our database). I am instead using other date fields that are within our database that are considered event dates for a row. Since these events are user inputted there can sometimes be dates that are not correct. To bypass this user error i am trying to load a max date where the max date is less then the date now. However with this script i am returning null values.
LET vTodayTY = Timestamp(Now(), 'MM/DD/YYYY hh:mm:ss');
MAX_DATE_TABLE:
Load Max(PRINTED_DATE) as MaxValue
from [lib://QVDs (adny1qlik01_qlikservice)/REQUISITIONS.qvd](qvd)
WHERE PRINTED_DATE < '$(vTodayTY)';
LET vMaxValue = TEXT(Timestamp((peek('MaxValue',0, 'MAX_DATE_TABLE')), 'yyyy-MM-dd hh:mm:ss'));
Try this
LET vTodayTY = Num(Now());
MAX_DATE_TABLE:
Load Max(PRINTED_DATE) as MaxValue
from [lib://QVDs (adny1qlik01_qlikservice)/REQUISITIONS.qvd](qvd)
WHERE PRINTED_DATE < $(vTodayTY);
LET vMaxValue = TEXT(Timestamp(Peek('MaxValue', 0, 'MAX_DATE_TABLE'), 'yyyy-MM-dd hh:mm:ss'));
Try this
LET vTodayTY = Num(Now());
MAX_DATE_TABLE:
Load Max(PRINTED_DATE) as MaxValue
from [lib://QVDs (adny1qlik01_qlikservice)/REQUISITIONS.qvd](qvd)
WHERE PRINTED_DATE < $(vTodayTY);
LET vMaxValue = TEXT(Timestamp(Peek('MaxValue', 0, 'MAX_DATE_TABLE'), 'yyyy-MM-dd hh:mm:ss'));
Thank you this solution worked and was implemented~!