Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
The goal is to find the rows including the values in NAME,
the wildmatch don't work in this case, please help me to correct it? Thank you very much!
TN:
LOAD
NAME
FROM
(qvd)
WHERE len(NOM_GROUPE) = 0;
let i = 1;
//set iend = 50000; //NoOfrows(TN);
do while i <= 50000
let NCom = '*' & peek(NAME, $(i), 'TN') & '*';
T:
load Distinct
NOM_GROUPE,
REF_GROUPE
FROM
(qvd)
where wildmatch(NOM_GROUPE, $(NCom) )=1
;
let i = i+1 ;
loop
;
Use Exists in this way:
TN:
LOAD
NAME
FROM
(qvd)
WHERE len(NOM_GROUPE) = 0;
load
NOM_GROUPE,
REF_GROUPE
FROM
(qvd)
where exists(NAME, NOM_GROUPE)
let me know
I'm sorry, what I want is NAME include NOM_GROUPE or NOM_GROUPE include NAME, not the same.
Ok,
then how many NAME you have from TN Table?
If you have not lots of names then you can concat NAME into a string then compare this string to the NOM-GRUPPE into the second load directly, without any loop
try,
let i = 1;
//set iend = 50000; //NoOfrows(TN);
do while i <= 50000
let NCom = peek(NAME, $(i), 'TN') ;
T:
load Distinct
NOM_GROUPE,
REF_GROUPE
FROM
(qvd)
where wildmatch(NOM_GROUPE, '*$(NCom)*" )=1
;
let i = i+1 ;
loop
;
It is hard to say why the wildmatch wouldnt work without looking at your data. could you upload a data sample may be?
Hi AdamiSliu
Please attach some sample data. Thank you.
hi AdamiSliu
What is this?