Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
aatish12345
Creator II
Creator II

How to write a code for subquery in Qliksense

Hi Everyone,

I have a SQL code, for example:

Select Column 1 from Table1 where

Column2  IN (select column3  from table 2)

 

I want to achieve this through qlik code.

 

Can someone help here plz...

 

Aatish

1 Solution

Accepted Solutions
jyothish8807
Master II
Master II

Hi @aatish12345 :

May be like this:

Table1:

Load 

column3 

from table 2;

Table2:

Load

Column 1 from Table1 where exists (column3 ,Column2);

Drop table Table1;

 

Best Regards,
KC

View solution in original post

2 Replies
abhijitnalekar
Specialist II
Specialist II

Hi Atish,

You can achieve the same by using the where Exist script function.

Please go through with the below link for example.

https://help.qlik.com/en-US/sense/August2021/Subsystems/Hub/Content/Sense_Hub/Scripting/InterRecordF...

Regards,
Abhijit
keep Qliking...
Help users find answers! Don't forget to mark a solution that worked for you!
jyothish8807
Master II
Master II

Hi @aatish12345 :

May be like this:

Table1:

Load 

column3 

from table 2;

Table2:

Load

Column 1 from Table1 where exists (column3 ,Column2);

Drop table Table1;

 

Best Regards,
KC