I am working on a project that consists in building a networking website like the Classmate web site.
I have proposed a database model based on the social media database model presented on the databaseanswers.org web site.
Does my database model match perfectly with my business rules? The rules are:
A provinces has one or many towns
A primary school belongs to a town
A high school belongs to a town
An institute belongs to a town
A university belongs to a town
A university or an institute has one or many departments
A university has one or many faculties
A university could have at least one or no institute
An institute could belong or not to a university; in the latter case it is independent
A person lives in a town located in a state
A person was born in a town located in a state
A person holds up to one user account
A user account attended a primary school or a high school or an institute or a university or an enterprise
A user account stores none or many messages
A user account sends or receives none or many messages
There are many types of messages
One user account could have a relationship (friend, colleague, classmate, ...) with another
There are many types of relationships
At registration an account could choose a primary school or a high school or an institute or a university or an enterprise
An account that has already chosen a primary school or a high school or an institute or a university or an enterprise can choose one or many more later
An account could display another account information
An account could display the list of its friends (relationship)
An account could display the list of the photos it has uploaded on the web site
An account could display the list of the photos related to the school it has attended or the enterprise it has worked in
An account could invite another account to be in relationship; the other account could accept or refuse the invitation.
An account could seek for its relationship
The administrator should be able to list all the persons' and all the users' accounts
The administrator should be able to list all the schools an account has attended
An account and the administrator could update the list of schools an account has attended