I've learned that within a weak entity, each occurrence can't be uniquely identified using any available attributes within that entity. In other words, each occurrences can't be uniquely identified since there is no primary key.
All the textbooks and online materials give a solution to this by saying that we can uniquely identify each occurrence only through a relationship with an owner entity's primary key.
My question: Is it possible to just add a primary key to a weak entity?
then, a weak entity becomes a strong entity and we don't need to go through an owner's entity to uniquely identify each occurrences within a weak entity.
Asked
Active
Viewed 372 times
0

Todd
- 399
- 3
- 18
-
Yes it is usually done exactly like that. – Michał Moskal Sep 26 '21 at 23:50
-
@MichałMoskal Thanks, you mean it is normal to add a primary key to a weak entity? – Todd Sep 26 '21 at 23:51
-
Every ORM tool that I worked with generates Primary Key on `id` field. – Michał Moskal Sep 26 '21 at 23:53
-
In real life I think this is normal, however theoretically not necessary. – Michał Moskal Sep 26 '21 at 23:55