May 16, 2006, 02:21 PM
Mark1IN LIKE
Is it possible to do an "IN LIKE..." or a "LIKE IN..." statement in Webfocus? I want to look up several values based on if they are like, but not exactly, my parameters.
May 16, 2006, 02:28 PM
susannahonly if you add a YOU KNOW to it.
May 16, 2006, 02:29 PM
LeahWhen you say in like do you mean if it were abc345, abc999, abc666, acc777 and you wanted all with 'abc'?
If so I've used the CONTAINS select
if field contains 'abc'
May 16, 2006, 02:43 PM
jimster06WHERE field LIKE 'mask' or
WHERE field NOT LIKE 'mask'
Masking characters are
_ (underscore) = any char in that position
% (pct sign) = any following sequence of zero or more char.
Look for 'Screening on Masked Fields'
May 16, 2006, 02:44 PM
Mark1You are right Leah. I am trying to do that. The deal is that I've got a name as a string split into different tokens. I want the last name, so I say if token four = "SR" then give me token three. The problem is that for one name, token four is padded with blank spaces, so I have to say if token four is like "SR%" then give me token three. The CONTAINS will work for the meantime, but I'm worried about someday when token four is "SRILANKA" or something like that.