You are viewing a single comment's thread. Return to all comments →
Less complex for the second SELECT:
select x, y from functions f1 where exists(select * from functions f2 where f2.y=f1.x and f2.x=f1.y and f2.x>f1.x) and (x!=y) union select x, y from functions f1 where x=y GROUP BY x, y HAVING COUNT(*) > 1 order by x;
Seems like cookies are disabled on this browser, please enable them to open this website
Symmetric Pairs
You are viewing a single comment's thread. Return to all comments →
Less complex for the second SELECT: