I am working with twitter data and need to store uid and friendId pair in a mysql table. My purpose is to create a network of friends and followers with the help of the table later.
I want to avoid duplicate pairs like (uid, friendId) and (friendId, uid) in the table.
Thank you
to avoid duplicate pairs do check
uid < friendIdbefore inserting.