I have a pair of users, and I want to find is the relationship between users allready exists, so I wrote this query, that I dont like.IT checks if
(partner1=user1 AND partner2=user2) OR (partner2=user1 AND partner1=user2)

SELECT n.nid FROM node n INNER JOINcompetition_pair p ON p.nid = n.nid INNER JOIN content_type_competition_pair c ON c.nid = n.nid WHERE n.type='competition_pair' AND ((c.competition_partner1_uid=%d AND c.competition_partner2_uid=%d) OR (c.competition_partner1_uid=%d AND c.competition_partner2_uid=%d)) AND p.active=1

How can I make this more simple?