Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I am using the code below to get the stats, it comes up as syntax error, I am unable to figure out why, your help is much appreciated.
SUB Stats;
LET vEndTime = Now();
LET vRecords = NoOfRows('$(vTable)');
LET vFields = NoOfFields('$(vTable)');
Statistics:
LOAD * From Statistics.QVD; //where TableName <> '$(vTable)';
Join (Statistics)
LOAD
DISTINCT
‘$(vTable)’ AS TableName,
‘$(vStartTime)’ AS StartTime,
‘$(vEndTime)’ AS EndTime,
'$(vRecords)' AS Records,
'$(vFields)' as Fields
RESIDENT Statistics;
STORE Statistics INTO Statistics.qvd;
DROP TABLE Statistics;
End SUB ;
If you only need the stats for each QVD you have,
I've done a quick example on how to do it if you don't have all the tables loads preaviously.
You just have to change the directory of the folder, and it will get all the QVDs on that particular folder and get the stats.
If you don't put anyhtin in the vDirFile variable, it will get the QVDs from the same path as the QVW.
Felipe.
Thanks so much Felipe.
No problem, glad to help