0

I am doing a design of a database, I have built my conceptual entity-relationship model and I have arrived at the physical implementation on mysql workbench. However, I find myself having to manage users who interact with the database.

For example, a student can only view data related to his exams and not all students. To do this I thought of introducing a "login" table containing "username", "password" and "user type" to connect this table to the table that contains the student's data, I should add a "username" attribute to this table . My question, however, concerns the following question: can I add these tables in the physical schema without inserting appropriate entities in the conceptual E-R schema, or do I have to insert the "login" entity in the conceptual schema as well?

Shadow
  • 33,525
  • 10
  • 51
  • 64
tecn603
  • 211
  • 5
  • 14
  • The conceptual schema exists for your benefit, and perhaps for the benefit of other people having to work on your implementation of it. You should ask yourself if you, and they, would benefit from the addition to the schema. – KIKO Software Feb 02 '21 at 11:31
  • I would like to understand if additions on a physical scheme are allowed, thus detaching from the conceptual model. That is, is this correct for the purposes of the design flow? – tecn603 Feb 02 '21 at 13:02
  • why do you want to introduce differences between the two models? – Shadow Feb 02 '21 at 14:26
  • Some entities in the database are also system users (with roles), I have to manage user logins to the database and I was thinking of creating a login table (username, password, type of user). However, a student must only be able to access their own exams and not all exams, so I would need to recognize that student at login (for example by adding the username attribute to the student entity, which refers to the username attribute of the table "login"). However, I have not considered the login aspects in the conceptual schema and I do not know if it is possible to insert this on a logical level – tecn603 Feb 02 '21 at 14:35
  • Logging in seems to be a basic function, so it would make sense to represent the items needed for that, and their relation to other items, in your conceptual schema. I'm sorry, but without a concrete schema to discuss this has got to remain vague. – KIKO Software Feb 02 '21 at 15:05
  • My fear is that the concept of "login" does not belong to the world described by the conceptual scheme, but is only an "implementation aspect". I can't understand the connection between conceptual and physical schema, the former should be independent of the physical, but I don't know if the physical can have additional aspects to the conceptual one. – tecn603 Feb 02 '21 at 15:39

0 Answers0