Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
flyhigh15
Contributor III
Contributor III

How to get Mismatch records between 2 tables

Table 1:
Load * inline [
Column1
1,
2,
3
];


Table 2:

Load * inline [
Column1
1,
2,
3,
4
] ;

 

i want output :

column 1

4

Labels (4)
1 Solution

Accepted Solutions
henrikalmen
Specialist
Specialist

Sorry, I accidentally removed the noconcatenate prefix in the edit I made.

A:
Load * inline [
Column1
1,
2,
3
];

B:
NOCONCATENATE Load * inline [
Column1
1,
2,
3,
4
]
where not exists(Column1)
;

drop table A;

View solution in original post

6 Replies
henrikalmen
Specialist
Specialist

This is one way. But how you really want to do it depends on your actual data model.

[Table 1]:
load * inline [
Column1
1,
2,
3
];


[Table 2]:
noconcatenate load * inline [
Column1
1,
2,
3,
4
]
where not exists(Column1)
;

drop [Table 1];

flyhigh15
Contributor III
Contributor III
Author

Gives error No records  not found @henrikalmen 

henrikalmen
Specialist
Specialist

I did not see you had a blank space in the table names, then they must be surrounded with brackets. So [Table 1] and [Table 2] in the names, and then drop table [Table 1] at the end. (I updated the post above.)

flyhigh15
Contributor III
Contributor III
Author

I have used below example

A:
Load * inline [
Column1
1,
2,
3
];

B:
Load * inline [
Column1
1,
2,
3,
4
]
where not exists(Column1,Column1)
;

drop table A;

exit Script;

 

Output:

No records found.. @henrikalmen 

henrikalmen
Specialist
Specialist

Sorry, I accidentally removed the noconcatenate prefix in the edit I made.

A:
Load * inline [
Column1
1,
2,
3
];

B:
NOCONCATENATE Load * inline [
Column1
1,
2,
3,
4
]
where not exists(Column1)
;

drop table A;

Pallav
Contributor II
Contributor II

Table1:
Load * inline [
Column1
1,
2,
3
];

NoConcatenate

Table2:

Load * inline [
Column1
1,
2,
3,
4
]
Where not Exists(Column1)
;

Drop Table Table1;