Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I'm using the following script to load identical QVD files:
Targets_Metrics:
LOAD *,
Target_Date as Date
From $(vPathTempData)Target_NO*.qvd (qvd);
STORE Targets_Metrics into $(vPathQVD)Targets_Metrics.qvd (qvd);
DROP Table Targets_Metrics;
But after dropping the table, there is a table with that name left in the model:
Why does it happen?
Thanks!
The QVD files do not have identical fields, so the QVD was not concatenated and a -1 table was created. The DROP table references the original table only. This script will enforce the concatenation:
Targets_Metrics:
LOAD 0 as Date AUTOGENERATE 0; // create empty table as concatenation target
Concatenate(Targets_Metrics) //force concatenation
LOAD *,
Target_Date as Date
From $(vPathTempData)Target_NO*.qvd (qvd);
STORE Targets_Metrics into $(vPathQVD)Targets_Metrics.qvd (qvd);
DROP Table Targets_Metrics;
The QVD files do not have identical fields, so the QVD was not concatenated and a -1 table was created. The DROP table references the original table only. This script will enforce the concatenation:
Targets_Metrics:
LOAD 0 as Date AUTOGENERATE 0; // create empty table as concatenation target
Concatenate(Targets_Metrics) //force concatenation
LOAD *,
Target_Date as Date
From $(vPathTempData)Target_NO*.qvd (qvd);
STORE Targets_Metrics into $(vPathQVD)Targets_Metrics.qvd (qvd);
DROP Table Targets_Metrics;
Thanks, Jonathan!
Tremendous help!
You are right... the tables were not identical..
The original script did concatenate and stored only the identical ones, and the table Target_Metrics-1 has the different one...