I believe that you are on the right path. The customer entity is different from the supplier entity. As a result, if a user is both a customer and supplier, he will have both a supplierID and CustID. This is shown in your diagram by the relationship with the User entity. However, the Customer entity will need to have a foreign key to link it to the User table. this will likely be UserID. Same for the Supplier entity.
how to implement/design this issue in object oriented design
-
22-06-2023 - |
Pregunta
its about internet shop program. Customer, products, Order, and supplier is involved. How to implement that the customer can be a product supplier in the same system ? How to design it and what is the idea to impelemnt it ?
this is what i have tested but im not sure if i did right.
Solución
Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow