Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I've the following script in Qlikview:
FinalOutput: select emp_id from employees;
Load * resident FinalOutput;
store FinalOutput into FinalOutput1(qvd);
Will the above
Load * resident FinalOutputstatement create duplicate entries in the output file
FinalOutput1?resident will not create any duplicates value .
you need to drop your base table.
Thanks Sunil,
How can I get the count of records in FinalOutput1(qvd)?
Load
from qvd
let var=noofrows('Tablename');
now use =$(var) in text box
Thanks,
Will Load Count(*) from <path>/FinalOutput1(qvd); work for counting the no. of records?
Will result be the same as with yours?
Qlikview is autoconcatenating your new table into the base table. To prevent it use noconcatenate keyword before load keyword while loading second table.
you can use count() function but in your case best will be just to use rowno() as rownum in your 2nd table while loading and then you can get count of records in a variable by using
let v_row_count = peek('rownum');
it will stop autoconcatenation also. but remember to drop your base table otherwise you will get synthetic keys.
hope this makes sense.
Regards,
Ashutosh
Thanks Ashutosh,
By new table and base table do you mean FinalOutput1 and FinalOutput resp.?
what is the second table that you are referring to?
Can you plz post the entire script...
Thanks,
second table is the new table which you made using resident.
script can be as
t1:
load
a,
b
from abc.qvd(qvd);
t2:
load
a,
b,
rowno() as rownum
resident t1;
let v_row_count_t2 = peek('rownum');
drop table t1;
drop field rownum;
Regards,
Ashutosh
yes its work same
but in your count(*) needs to add group by