Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
buenas tardes:
me gutaria saber como puedo unificar varios QVD's, ya que se generan 1 por dia. hay alguna forma de que se puedan cargar varios y con forme pasen lo dias se sigan cargando
Espero me pueda apoyar
Hi,
This is very easy: you can use the wild card asterisk * to load all QVDs files for years 2022 and 2023:
First create a load script with a table to load year 2022, name it for example lFN.
And later concatenate lFN to load year 2023. See below the script:
lFN:
Load * from [lib://QVDs/MX_DDV_Inventory_*2022.qvd] (qvd);
Concatenate(lFN)
Load * from [lib://QVDs/MX_DDV_Inventory_*2023.qvd] (qvd);
I recommend you first to create these QVDs files with date format YYYYMMDD, because it is better if you want to extract or load them by month.
Hi,
This is very easy: you can use the wild card asterisk * to load all QVDs files for years 2022 and 2023:
First create a load script with a table to load year 2022, name it for example lFN.
And later concatenate lFN to load year 2023. See below the script:
lFN:
Load * from [lib://QVDs/MX_DDV_Inventory_*2022.qvd] (qvd);
Concatenate(lFN)
Load * from [lib://QVDs/MX_DDV_Inventory_*2023.qvd] (qvd);
I recommend you first to create these QVDs files with date format YYYYMMDD, because it is better if you want to extract or load them by month.
buenas tardes:
hay alguna forma de que si en el QVD no tiene la fecha de creacion la pueda insertar cuando se hace la carga masiva??
Muchas garcias por la ayuda
It is more complex, but you can resolve it using these lines, please try this:
Let vfile='MX_DDV_Inventory_*.qvd';
lFN:
Load * Inline [Field99];
For Each vfile in FileList('[lib://QVDs/MX_DDV_Inventory_*.qvd]')
vdate=TextBetween(vfile,'MX_DDV_Inventory_','.qvd');
vcreatedate=MakeDate(Mid(vdate,5,4),Mid(vdate,1,2),Mid(vdate,3,2));
Concatenate
Load Field1,Field2,Field3,Date#('$(vcreatedate)') AS CreatedDate from '$(vfile)' (qvd);
Next vfile;
Drop Field Field99;