I use an incremental load to load 3 reports into qlikview. I have written my code so that a table is created with the reports from the latest date for which all reports are available. The table looks like this (in order of loading):
file report category
In my script I write the following code:
I would think this code gives me the filename of the file that I want to load, but apparently every vReport leads to the same result; it always results in filename3, even though the fieldindex formula returns a different number. What am I doing wrong here?
Table1 only has the 2 fields that I described, filename and category
Please note that I loaded category as right(filename, 6), since the last bit of the filename describes to which category it belongs.
When I load table1 and create a table object, I see no duplicate values. Just the 3 file names and their respective categories.
vReport1=peek('file'0,'table1) also yields filename3. No matter which number I use as a row number in the peek function, it returns the same filename. Even when I use 10, even though there are only supposed to be 3 rows in my table.