Skip to main content

Rules: Not in join

  • February 4, 2021
  • 2 replies
  • 23 views

andreammelde
Forum|alt.badge.img+3

It would be really helpful to have an option to exclude from a join. This is intended for “exceptions”. Right now, I have to do a full left join and then a transform to get this. It would be great to be able to do this in one step.

 

SQL example:

select * from TABLE_1

where Unique_ID is not in

(select Unique_ID from TABLE_2)

2 replies

sai_ram
Forum|alt.badge.img+1
  • Expert ⭐️⭐️
  • February 4, 2021

@andreammelde Thanks for sharing this, I will check on this and get back to you. 


rakesh
Forum|alt.badge.img+2
  • Lets put your data to work!
  • February 4, 2021

Hi @andreammelde  we do not support nested queries directly. But we can achieve what you want. 

 

Do a left join of TABLE_1, TABLE_2 on Unique_ID. Then filter for TABLE_2.Unique_ID =! null