Skip to content
Advertisement

Compare values in Different column and row

I have the following table:

What I need is to select all rows where Col1 value is available in Col2 and vice versa.

This case only ROW 4 or ROW 3 should be returned. They have same values (13 17).

Take it as col1 is Buyer and col2 is Seller

I want to know who are the users who bought / sell from EACH OTHER. if user a bought from user b, user b should buy from user a in order to be returned.

Advertisement

Answer

User contributions licensed under: CC BY-SA
10 People found this is helpful
Advertisement