Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hi all,
iam trying to load multiple qvd's- there are totally 3 files
Set vFolder = 'D:\QVD';
for each File in filelist(vFolder& '\*.QVD')
QUALIFY*,;
UNQUALIFY ID;
[QVD multiple]:
LOAD ID,
Account,
Month,
Year,
Quantity,
Subscriber,
[SubscriberGroup],
[SubscriberPartner],
[Subscriber Center],
[Amount ],
from [$(File)] (qvd);
UNQUALIFY*;
next File
but my data model is not one.. it is generating 3 different tables . i require one ta
if column names are same try below
LOAD * INLINE
Field_A, Field_B, Field_C, Field_D
];
FOR EACH vFile in FileList('C:\MYDATA*.qvd')
CONCATENATE
LOAD * FROM [$(vFile)] (qvd);
NEXT vFile
Hi Raadqiptec,
Use this code
Set vFolder = 'D:\QVD';
for each File in filelist(vFolder& '\*.QVD')
Temp:
Load
ID,
Account,
Month,
Year,
Quantity,
Subscriber,
[SubscriberGroup],
[SubscriberPartner],
[Subscriber Center],
[Amount ],
from [$(File)] (qvd);
next File;
********************************************************************************
QUALIFY *;
UNQUALIFY ID;
[QVD Multipe]:
LOAD
*
Resident
Temp;
UNQUALIFY *;
Drop table Temp;
Hi
As far as i Know
One table ...one qvd (viceversa).
For you case try some JOIN in the code itself !!?
Set vFolder = 'D:\QVD';
for each File in filelist(vFolder& '\*.QVD')
QUALIFY*,;
UNQUALIFY ID;
[QVD multiple]:
JOIN
LOAD ID,
Account,
Month,
Year,
Quantity,
Subscriber,
[SubscriberGroup],
[SubscriberPartner],
[Subscriber Center],
[Amount ],
from [$(File)] (qvd);
UNQUALIFY*;
next File
I believe it should be Concatenate
you are qualifying the tables so the field names will be likely different.
They wont auto-concatenate with the different field names.
You will have to outer join them instead
Hi, Don't use Qualify.
Regards!
hi manua
l the probelem is i have already another table with the same fields.. to avoid it iam qualifying as they are not supposed to concatenate
your original question stated that you wanted one table - if you don't qualify the tables you will get one as they will auto-concatenate, if you qualify you will get multiple.
you could load it without qualifying and specify noconcatenate between them but they will be part of a big synthetic key. You would be able to resident from them or join them later though in your script.
what are you trying to achieve here?
Then, change the names to the fields with as.
Regards!