I am starting a whole project by myself for the first time, and I am stuck between the UML modelization ( Class diagram ) and the database structure.
Should I use the exact same classes that I model in the class diagram in the database?
For example, I have two User
, the Service_provider
and the Client
. In the class diagram I consider each one of them as a unique class. But I chose to use single table inheritance in the database, so I store both users in the same table and add the role attribute to it.
Does my modelization stay valid in this case? or I just need one class for User
? (but in this case, I can't show the relationship between the Service_provider
and the Client
as the Service_provider
could have many Clients
)
Could anyone explain this to me, please?