this.con = connectToDB ();
wenn (Betrug! = Null) {
Schnur Frage = ""
Aussagenaussage = this.con.createStatement ();
ResultSet resultSet = statement.executeQuery (Frage);
searchResult = neuer Vektor ();
int I = 0;
wenn (resultSet! = Null) {
während (resultSet.next ()) {
System.out.println („ich " +i+1);
Name der Schnur [] = resultSet.getString („NAME“) .split (“, ");
Lehrkörper-facutlty = neue Lehrkörper (
resultSet.getString („PERSON_UID“),
Name [1] + " „+name [0],
resultSet.getString („GOBTPAC_LDAP_USER“),
resultSet.getString („SYRREIN_INTEREST“));
searchResult.add (facutlty);
}
}
statement.close ();
resultSet.close ();
closeConnection (Betrug);
}
RückholsearchResult;
} Fang (SQLException sqlException) {
this.logger.log zeichnet (this.formatter.format (this.today) + „: searchFacultyInterest: Ausfallen“);
this.logger.log zeichnet (this.formatter.format (this.today) + „: SQLException: “ + sqlException.getMessage ());
closeConnection (this.con);
Rückholnull;
} Fang (NullPointerException nullPointerException) {
this.logger.log zeichnet (this.formatter.format (this.today) + „: searchFacultyInterest: Ausfallen“);
this.logger.log zeichnet (this.formatter.format (this.today) + „: NullPointerException: “ + nullPointerException.getMessage ());
closeConnection (this.con);
Rückholnull;
}
|