Few issues fix

Added 'required' attribute to certain input fields. Query updated to
match new database fields