Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have attached a QlikView Document which looks at a Excel spreadsheet (also attached), when creating the QVD I want to use the distinct values from Fin Year and Fin Period and use these as part of the QVD name.
So for example I would like the QVD Name to be:
Fact_2017_10.qvd
STORE Fact into 'C:\Temp\Fact' &'_'&[Fin Year]&'_'&[Fin Period]'&.qvd (QVD);
Thanks
Load another table with Distinct values and load fin year and fin month rows in a variable and then add to store command.
DateFields:
LOAD Distinct [Fin Year] as Fin_Year,[Fin Period] as Fin_Period Resident Fact;
LET vFinYear = Peek('Fin_Year',0,'DateFields');
LET vFinMonth = Peek('Fin_Period',0,'DateFields');
STORE Fact into Fin_$(vFinYear)_$(vFinMonth).qvd (QVD);
DROP Table Fact;
Load another table with Distinct values and load fin year and fin month rows in a variable and then add to store command.
DateFields:
LOAD Distinct [Fin Year] as Fin_Year,[Fin Period] as Fin_Period Resident Fact;
LET vFinYear = Peek('Fin_Year',0,'DateFields');
LET vFinMonth = Peek('Fin_Period',0,'DateFields');
STORE Fact into Fin_$(vFinYear)_$(vFinMonth).qvd (QVD);
DROP Table Fact;
Maybe something like
LET vFile = 'C:\Temp\Fact_'& FieldValue('Fin Year',1) &'_'& FieldValue('Fin Period',1)& '.qvd';
STORE Fact into [$(vFile)] (QVD);
Thanks!