Design a friends table for a social networking site
<p>Hi i am facing problem regarding the structure of a table for storing the all the friends list of an user. In the below table which i have used if user <strong>84</strong> has requested for friendship with user <strong>70</strong> &amp; <strong>74</strong> then user <strong>84</strong> is friends are <strong>70 &amp; 74</strong> and vice versa. Similarly user <strong>77</strong>  with <strong>84</strong>.</p>

<p><a href="https://i.stack.imgur.com/u0rz3.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/u0rz3.png" alt="enter image description here"></a></p>

<p>But the problem is that if i want to find out all the friends and their detail of user <strong>84</strong> i.e. of user (<strong>70,74,77</strong>).</p>

<p>Should i enter duplicate record like image 2 Ex: if user <strong>84</strong> send friend request to user <strong>70</strong> when user <strong>70</strong> accept the request then another row will be inserted like <strong>user_id 70 &amp; friend_id 84</strong>.</p>

<p>OR is there any mysql query to join with users table based on the column value of the friends table. Like if <strong>user_id is 84</strong> it will join based on the <strong>friend_id</strong> and if <strong>friend_id is 84</strong> then it will join with user table by using the <strong>user_id</strong> column.</p>

<p><a href="https://i.stack.imgur.com/88ccR.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/88ccR.png" alt="enter image description here"></a></p>