Added user types and fixed SQL Bug
Changed sql tables