It compares each row from the left. In the end what i want to get is the followings: For that to work, you need to add a where clause with the is null.
Meaghan Rath 02/07/2023 • CelebMafia
Pyspark left anti join is simple opposite to left join.
In pyspark sql, a leftanti join selects only rows from the left table that do not have a match in the right table.
Here’s how the leftanti join works: This join will work mainly with left dataframe. I tried left_anti join but i haven't been successful. An anti join returns values from the left relation that has no match with the right.
As alluded to in the introduction, it's also possible to perform an anti join using left and right joins. An anti left join, also known as a left join with exclusion, is a query pattern used to retrieve rows from one table that do not have corresponding rows in another table. It is also referred to as a left anti join. It shows the only those records which are not match in left join.