Question: Convert a ER model into a relational database schema expressed in SQL DDL, with appropriate constraints. Use Create Table Command Friends and Groups Friends and
Convert a ER model into a relational database schema expressed in SQL DDL, with appropriate constraints.
Use Create Table Command
Friends and Groups
Friends and Groups both represent collections of people, but in the case of Groups they are collections of people who are users. Since the membership relations refer to different entities, we also treat Friends and Groups as different entities. The following diagram shows entities, attributes and relationships that deal with various groups of people on the pics.net site. Note that, to keep things simple, we are completely ignoring the process by which users become members of groups; this would typically require additional tables related to invitations and requests.

Comments on Friends:
users can build lists of people they know (e.g. friends or family)
every Friends list must have a title (e.g. "Family", "Workmates", "Friends")
such lists cannot be empty; the list is created when the first member is added
all members of a Friends list must be entered into the database as people
Comments on Groups:
groups are also created by users; the creator becomes the owner
groups also have IDs and titles, and must have a mode to describe how membership of the group is organised
any user may be a member of multiple groups; every group must have at least one member (the owner is automatically a member)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
