LOOKUP with partial string
Moderators: chulett, rschirm, roy
-
- Premium Member
- Posts: 43
- Joined: Wed Feb 08, 2012 8:12 pm
- Location: United States
LOOKUP with partial string
Hi,
Is their way to do lookup with partial string match?
Like I am looking for a presence of one word in a primary link rather than exact field match and consider it to be matched.
Thanks
Is their way to do lookup with partial string match?
Like I am looking for a presence of one word in a primary link rather than exact field match and consider it to be matched.
Thanks
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
I can confirm sparse lookup using LIKE condition does work with the DB2 Connector stage. Oracle also supports sparse lookups. It would be nice if you could do a wildcard match in the Lookup stage no matter what stage was on the reference link. As far as I know you can do exact matches, caseless matches, or range lookups, but not exactly wildcards...
Choose a job you love, and you will never have to work a day in your life. - Confucius
-
- Participant
- Posts: 597
- Joined: Fri Apr 29, 2005 6:19 am
- Location: Singapore
Re: LOOKUP with partial string
You can, by this method. Suppose your one word is 'dummy'. Search both input and look up key column for this word & if found, populate a new column with value 'dummy'. For other records, populate this new column with original key value. Now do a look up using this new column as key and you can get that you need.BuddingDev wrote:Like I am looking for a presence of one word in a primary link rather than exact field match and consider it to be matched.
It's friday, so take it easy
Kandy
_________________
Try and Try again…You will succeed atlast!!
_________________
Try and Try again…You will succeed atlast!!
-
- Participant
- Posts: 597
- Joined: Fri Apr 29, 2005 6:19 am
- Location: Singapore
Kandy, are you suggesting using Index() and perhaps making 2 passes through the data? Sounds like that may work to match a partial string and it would simply add extra processing time. I'll have to try it "in my free time." I may have to start my own topic on that later, because I need to do wildcard lookups in real-time web service jobs with NO database I/O (i.e. no sparse lookups).
Choose a job you love, and you will never have to work a day in your life. - Confucius
-
- Participant
- Posts: 437
- Joined: Fri Oct 21, 2005 10:00 pm
Your best case is to write a custom operator to do this work. It may be possible to do wildcard lookups through a series of passes through the data -- but this will never be as effecient as a custom op to get the work done in real time or batch for that matter.
Keith Williams
keith@peacefieldinc.com
keith@peacefieldinc.com
-
- Premium Member
- Posts: 43
- Joined: Wed Feb 08, 2012 8:12 pm
- Location: United States