Optimize tables in Database

0

Good morning, I'm modifying an app where access to different user types is required, the app has a table for each type of user (if the app works) but if you create N types of users you would have to create N tables which I do not see as feasible.

Now I want to place only one table users as in the following image, the problem is that I do not know how to shred it so that I can make the same references in the table articles

I am very grateful that you can guide me, thank you.

    
asked by Silvestre Silva 18.01.2018 в 17:52
source

1 answer

0

The table artuculos only requires an FK that would be the FK of the table usuarios and users requires an FK corresponding to the table tipoUsuario table that you will have to create which will store all the types of users that come up with a very basic example is the following: I hope you clarify greetings;

    
answered by 18.01.2018 в 18:22