How to write select statement for find friends( like facebook find friends concept) ?
Hi,
I have two tables
1.User table - UserId is primary key
2.Friends table - FriendsId is primary keys
In User table I have all users list
I want to get records from following relation
User->Friend->SubFriend
User has some Friends and
Each Friend has some subfriends
requirement:
How to write select statement for get all subfriends list,
Thank you in advance