Is following way is right Database model for following problem?
Here are two different possible solutions.

Solution 1:


Solution 2:


For both models, Users is a parent table, with different tables subclassing it. This is achieved by the primary key of the child tables also being a foreign key to the Users' primary key.

Solution 1 involves having a list of possible user roles in the Roles table (Administrator, School, Teacher, Student) with the User having a reference to a role.

Solution 2 involves deriving the idea of the User's role from which child table the User belongs to. This would mean that a row belonging to Users must also belong to one of the child tables.

I personally like the first solution better, since it separates the idea of a Users' role in the portal from the User's position within the school environment.

As an additional note, I would look into "salted password encryption" for storing passwords, especially if this database is for a real application.