Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have two qvd files with following Fields
QVD 1
IDNO,PRD,CLASS,AMOUNT
QVD 2
IDNO, COUNT
I want to load data from table qvd1 if IDNO exists in table qvd2. Please help me to write the script
QVD 1
ID NO,PRD,CLASS,AMOUNT from..........
where exits(IDNO);
Concatenate
QVD 2
IDNO, COUNT
from...........
Hi,
Use exists() in where clause of first qvd
Regards,
Thanks Max
Could you please write the full script
Hi,
Try like this
Final_qvd
Load IDNO as temp_IDNO,
COUNT
from QVD2;
join
load *
from QVD1
where exists(temp_IDNO,IDNO);
Regards,
Hi,
You can use Keep Keyword to do this
use this Script
LOAD IDNO,
Count
FROM
D:\Vivek\Community\QVD2.qvd
(qvd);
Left Keep
LOAD IDNO,
PRD,
CLASS,
AMOUNT
FROM
D:\Vivek\Community\QVD1.qvd
(qvd);
Regards,
Vivek
QVD 1
ID NO,PRD,CLASS,AMOUNT from..........
where exits(IDNO);
Concatenate
QVD 2
IDNO, COUNT
from...........
Thanks all
Hi,
If you dont want to join two tables
then
Try like this
QVD1:
Load IDNO as temp_IDNO,
COUNT
from QVD2;
QVD1:
load *
from QVD1
where exists(QVD1.temp_IDNO,IDNO);
Regards,