Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
andewan
Contributor II
Contributor II

Exclude records in the output chart based on value comparison with another column

***New to Qlik sense***

Data model:

TABLE_1:

Product_ID Product_name Cost
xy_123 table 14
sub_481 chair 27
xy_102 fan 18

 

TABLE_2:

Sub_product_id Sub_product_name Cost
sub_481 chair 27

 

I need to make a chart for Table 1 but exclude records which are present in Table 2. I.e. how can I exclude the sub_481 record from the chart? Also, I need to exclude the records at the chart/sheet level, not at the script. 

Labels (4)
2 Replies
Taoufiq_Zarra

@andewan  do you want to remove the records at the script level?

TABLE_2:

LOAD * INLINE [
    Sub_product_id , Sub_product_name , Cost
    sub_481 , chair , 27
];

TABLE_1:
LOAD * INLINE [
    Product_ID , Product_name , Cost
    xy_123 , table , 14
    sub_481 , chair , 27
    xy_102 , fan , 18
]WHERE NOT Exists(Sub_product_id, Product_ID);

drop table TABLE_2;

 

output:

Taoufiq_Zarra_0-1678131742286.png

 

Regards,
Taoufiq ZARRA

"Please LIKE posts and "Accept as Solution" if the provided solution is helpful "

(you can mark up to 3 "solutions") 😉
andewan
Contributor II
Contributor II
Author

@Taoufiq_Zarra Thank you for your response 🙂

I have edited my question - I need to remove the records not at the script but at the chart/sheet level.