Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Everyone,
How can I replicate the following SQL in QlikView (problem is the like statement):-
select top 1 1
from #ABC a
join #DEF b
on a.Product like '%' + b.Product + '%'
Since QV will join it automatically, how can I join it using LIKE?
If your data source is SQL then you could use sql syntax to first load the like-table with all possible matches from sql into a QV mapping table,
then use applymap() in QV script.
Hi!
In QV instead [%] in SQL
so expression in SQL a.text like '%default%'
in QV will be a.text like '*default*'
Hope it will help.
My data source now is QVD... so can't use the SQL syntax. 😕
I meen that in QV you can use star ( * ) instead ( % )
You can use it anywhere in QV, in expression, for example.
Hi,
Thanks for the suggestion. But I'm actually referring to Tanel's post.
As for your suggestion, my issue is that I need to do the JOIN in script. As you know, QlikView joins the tables automatically based on the same field name. How can I use * to do a fuzzy/LIKE join?
Hello.
The wildmatch command performs a comparison and allows wildcard characters. I have attached a small sample application using this command when joining two tables.
Let me know if this helps.
John.