public void findStaffOnProject(Project project){
          try{
                     SetOfUsers staffOnProject = new SetOfUsers();
                     ResultSet staffResults = null;
                     Statement statement;
                     statement = connection.createStatement();
                     staffResults = statement.executeQuery( "SELECT Project.projectID, User.userID, User.firstName, User.surname, Staff.role" +
                    "FROM User INNER JOIN (Staff INNER JOIN (Project INNER JOIN StaffOnProjects ON Project.projectID = StaffOnProjects.projectID)"
                             + " ON Staff.staffID = StaffOnProjects.staffID) ON User.userID = Staff.staffID"
                             + "WHERE Project.projectID=" + project.getProjectID() + ";");                     
                     
                     while (staffResults.next())
                    {
                        for(int i=0;i<allUsers.size();i++){
                            if(allUsers.get(i).getUserID()==staffResults.getInt("staffID")){
                                staffOnProject.addUser(allUsers.get(i));
                            }
                        }
                    }
        }catch(Exception e){
            JOptionPane.showMessageDialog(null,e);
        }
     }