Changeset 8771


Ignore:
Timestamp:
2004-12-09T16:30:32+13:00 (19 years ago)
Author:
schweer
Message:

bugfix; calling getString() without calling next() before that results in an SQLException...

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/gs3build/notifier/NotifierManager.java

    r8770 r8771  
    153153    private String getDocumentTitle(String documentID, GS3SQLConnection database) {
    154154        Statement statement = database.createStatement();
     155
    155156        ResultSet results;
    156157        try {
     
    166167                    "                                 AND m.docID = s.docid;";
    167168            results = statement.executeQuery(sqlString);
    168             return results.getString(0);
     169            if (results.next()) {
     170                return results.getString(0);
     171            }
    169172        } catch (SQLException e) {
    170             return "";
    171173        }
     174        return "";
    172175    }
    173176
Note: See TracChangeset for help on using the changeset viewer.