Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
In my load script I only want to load records that that meet a certain criteria i.e:
LOAD *
from Services
WHERE
MID(NOTE_TEXT,1,4) IN (
'FM02', 'FM03', 'FM04', 'FM05', 'FM06', 'FM07',
'FM08', 'FM09', 'FM10', 'FM11', 'FM12', 'FM13',
'FM14', 'FM15', 'FM16', 'FM17', 'FM18', 'FM19',
'FM21', 'FM22', 'FM23', 'FM24', 'FM26', 'FM28',
'FM29', 'FM30', 'FM31', 'FM32', 'FM33', 'FM35' )
hOW CAN THIS BE ACHEIVED IN qv ?
Any thoughts ?
Many thanks
hi,
one way is to use the "match" function:
match( str, expr1 [ , expr2,...exprN ] )
The match function performs a case sensitive comparison.
Example:
match( M, 'Jan','Feb','Mar')
returns 2 if M = Feb
returns 0 if M = Apr or jan
so for your case
load *
from Services
where match(mid(NOTE_TEXT,1,4),'FM02','FM03' etc. etc.)>0
hi,
one way is to use the "match" function:
match( str, expr1 [ , expr2,...exprN ] )
The match function performs a case sensitive comparison.
Example:
match( M, 'Jan','Feb','Mar')
returns 2 if M = Feb
returns 0 if M = Apr or jan
so for your case
load *
from Services
where match(mid(NOTE_TEXT,1,4),'FM02','FM03' etc. etc.)>0
Hi,
... and wildmatch uses *:
... where wildmatch(Mid(NOTE_TEXT,1,4),'FM02',...,'FM09','FM1*','FM2*');
Excellent Martina - just the job !
Pat Agen - brilliant works well !