Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
QlikWorld, June 24-25, 2020. Free virtual event for DI and DA gurus. Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Contributor
Contributor

Text Comparison not working

I have a simple yet not working expression that does not seem to change output no matter what here is the following example shown below.

Both are Excel tables from different Excel Files

Master_names
Bond,James
Smith,Will
Wahlberg,Mark

Check_List

Smith,Will

I want to output the Master_names not in the check_List table so I wrote the following expression to output a table object.

if(Master_names <> Check_List, Master_names) // this outputs the entire Master_names table


outputs this

OUTPUT
Bond,James
Smith,Will
Wahlberg,Mark

My question is what am I doing wrong I check for the string length and Trim functions to remove any white spaces or leading white space.

This is the desired output

Desired Output
Bond,James
Wahlberg,Mark
5 Replies
Highlighted

Re: Text Comparison not working

May be try this

Check_List:

LOAD Check_List

FROM ....;

Master_Names:

LOAD Master_Names

     ...

FROM ....

Where not Exists(Check_List, Master_Names);

Highlighted
Champion III
Champion III

Re: Text Comparison not working

Try this may be:

Text2:

LOAD * INLINE [

Check_List

'Smith,Will'

];

Text1:

LOAD * INLINE [

Master_names

'Bond,James'

'Smith,Will'

'Wahlberg,Mark'

];

NoConcatenate

Final:

LOAD *

Resident Text1

WHERE NOT Exists(Check_List, Master_names);

Drop Table Text1;

Replace the inline loads with your Excel source.

Highlighted
Contributor
Contributor

Re: Text Comparison not working

Thank You for answering, but I need it to where the data is not "fixed" or known on any of the tables. 

Highlighted
Contributor
Contributor

Re: Text Comparison not working

How would I do this within the expression editor ex. building a visual table within the app.

Thank You

Highlighted

Re: Text Comparison not working

May be using set analysis in your expression

{<Master_Names = e(Check_List)>}