Quote:
|
Originally Posted by freeBatjko
Here's another thought:
For example:
A requests to be friends with B, but needs to wait until B approves.
You want to record this status as a "possible (mutual) friendship" and then convert it into a "mutual" friendship when approved.
My first thought would be to simply add another column to the friends table as proposed above, like
Friends(user_id, friends_user_id, how_do_you_know_eachother, status),
where "status" could have values like "requested" and "approved".
Hm... 
|
if B refuses the request from A, should the record be removed then?
I found Facebook's database schema from the Internet, and there is a table named FriendRelation. property "AreFriends" should identify the relationship between two people and I guess its type is boolean