Good day! The database has a table with roles and three tables responsible for the users: the customer, the printing house and the administrator. These three tables are related to the roleId table of roles, i.e. each user has a specific role.

Next, I try to set up authorization, create my MyRoleProvider, inherit from RoleProvider and implement the methods GetAllRoles () and GetRoleForUser (string username). But the fact is that I can’t get a role for a specific user by his name, because I have three tables with users, and I’m somehow not very good at checking out each of them. Tell me how best to organize it all.

  • As it does not really have three tables with users. But since they are there, then check them all \ - tym32167

1 answer 1

And why do you need three tables for users? Do these users have such a different set of fields? If yes, then select common fields in the Users table and create additional tables, such as Admins and Customers