Skip to main content
Announcements
July 15, NEW Customer Portal: Initial launch will improve how you submit Support Cases. IMPORTANT DETAILS
cancel
Showing results for 
Search instead for 
Did you mean: 
Rihaan786
Contributor
Contributor

Qliksense partial check and flag

Hello Experts

Am new to qlik and working on a project where I have to do partial string comparison and flag it as yea and no from 2 columns.

Column A.   

Hello world

Function new

Syzmon Limited

 

Column B

Hello Python

FunctionNew

Content Limited

As per the example given for the column A and B ...

 

Answer in C column should be

Column C

Yes

No

Yes

Hope my question make sense as that ia my requirement with million rows

Thanking you in Advance

 

 

Labels (1)
3 Replies
rubenmarin

Hi @Rihaan786, so you want to comapre orw by row if there is an exact word in both columns? In that case you can try this:

// Sample data
Data:
LOAD * inline [
RowData,Column A,Column B
1,Hello world,Hello Python
2,Function new,FunctionNew
3,Syzmon Limited,Content Limited
];

// Split words of each column, for each RowData it cretes a cartesian product of all the words, if any is equal it's flagged as 'Yes'
DataByWords:
LOAD
	RowData,
	If(WordsA=WordsB, 'Yes', 'No') as [Column C]
;
LOAD
	RowData,
	Subfield([Column A], ' ') as WordsA,
	Subfield([Column B], ' ') as WordsB
Resident Data;

// Add to the original data the higer alphetic value (if it has any Yes it adds Yes, if none it adds No)
Left Join (Data)
LOAD
	RowData,
	MaxString([Column C]) as [Column C]
Resident DataByWords
Group by RowData;

DROP table DataByWords;

 

Anonymous
Not applicable

Thank you so very Much...Works lik magic.

Anonymous
Not applicable

Hello Ruben sir.

That was a great help.

Need one more suggestion on similar lines.

 

I have one column with key words in table A and one columne in Table B with Address and need to check the keyword in the from Table A if matches in Table B.

Example

TABLE A

/Aa/

Qlik

Sense

Qlik view

Python programming

 

TABLE B

New Jersey /Aa/

The Python programming is best

Qlik is Bi

United states of America

United kingdom

 

As per the example

/Aa/ is matching

Python programming is matching

Qlik is matching

 

 

So third column should have match and no match flag.

My keywords are 100 and Table b data is 1 million.

 

Hope my question is clear. I tried with Applymatch as this is kind of lookup in Excel.

Thanking you in advance.