Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
isciberras
Creator
Creator

Comparing a sentence to a list of words

Hi everyone,

I have two separate tables one with a list of words and the other with a short sentence for example:

Words to checkJournal Description
error2018 paperwork error
correctionerror in posting caused by xyz
reversaljournal reversal in quarter 1
deferredthis is a standard journal
this is a journal that is deferred

I would like to compare the table containing (Words to check) with the (Journal Description) table. Essentially I want to do some form of fuzzy matching with the whole sentence found in journal description with the keywords found in (Words to check) table.

Does anyone know if I can achieve this using Qlikview?

Thanks,
Isaac

1 Solution

Accepted Solutions
MarcoWedel

Hi,

one solution might be:

QlikCommunity_Thread_311268_Pic1.JPG

QlikCommunity_Thread_311268_Pic2.JPG

tabCheckWords:

LOAD [Words to check],

    AutoNumber([Words to check],'CheckWords') as %WordID

FROM [https://community.qlik.com/thread/311268] (html, codepage is 1252, embedded labels, table is @1)

Where Len(Trim([Words to check]));

tabJournDescript:

LOAD RecNo() as %JournDescID,

    [Journal Description]  

FROM [https://community.qlik.com/thread/311268] (html, codepage is 1252, embedded labels, table is @1)

Where Len(Trim([Journal Description]));

tabLink:

LOAD *

Where Exists (%WordID);

LOAD %JournDescID,

    AutoNumber(SubField([Journal Description],' '),'CheckWords') as %WordID

Resident tabJournDescript;

hope this helps

regards

Marco

View solution in original post

5 Replies
Gysbert_Wassenaar

I'm not sure what you really want to do, but you could simply load all the sentences and add a listbox for that field and do a fuzzy search in the listbox. Type in *error* (including the starting and ending * wildcard characters) and you'll see the sentences filtered to show only those containing the word error.


talk is cheap, supply exceeds demand
MarcoWedel

Hi,

one solution might be:

QlikCommunity_Thread_311268_Pic1.JPG

QlikCommunity_Thread_311268_Pic2.JPG

tabCheckWords:

LOAD [Words to check],

    AutoNumber([Words to check],'CheckWords') as %WordID

FROM [https://community.qlik.com/thread/311268] (html, codepage is 1252, embedded labels, table is @1)

Where Len(Trim([Words to check]));

tabJournDescript:

LOAD RecNo() as %JournDescID,

    [Journal Description]  

FROM [https://community.qlik.com/thread/311268] (html, codepage is 1252, embedded labels, table is @1)

Where Len(Trim([Journal Description]));

tabLink:

LOAD *

Where Exists (%WordID);

LOAD %JournDescID,

    AutoNumber(SubField([Journal Description],' '),'CheckWords') as %WordID

Resident tabJournDescript;

hope this helps

regards

Marco

MarcoWedel

see also:

Pair of words from sentence

QlikCommunity_Thread_311268_Pic3.JPG

QlikCommunity_Thread_283581_Pic4.JPG

hope this helps

regards

Marco

isciberras
Creator
Creator
Author

Wow thank you that's exactly what I wanted to achieve and it worked perfectly! Thank you so much for your help

MarcoWedel

you're welcome

glad it helped

regards

Marco