Method for retrieving all registered users from database