Friendship and Networking
I’ve just finished the networking part of the MuzikMekan application. Now, users are able to send friendship request to others, display them and accept or reject them. This is implemented using two database tables: Friend and FriendRequest. First table consists of user pairs who are friends in the system. If user with id=1 and id=2 are friends, Friend table include two entries as (1,2) and (2,1). This technique is used to facilitate database operations when checking friends of a user. Second table is used to keep friendship requests. If user with id=3 asks for friendship to user with id=4, an entry with columns (3,4) will be exists in the FriendRequest table.