code: ThrowableInformation getException(Connection connection, long id)
        throws SQLException {
  
      PreparedStatement statement = null;
  
      try {
        statement = connection.prepareStatement(sqlException);
        statement.setLong(1, id);
        ResultSet rs = statement.executeQuery();
  
        Vector v = new Vector();
  
        while (rs.next()) {
          //int i = rs.getShort(1);
          v.add(rs.getString(1));
        }
  
        int len = v.size();
        String[] strRep = new String[len];
        for (int i = 0; i < len; i++) {
          strRep[i] = (String) v.get(i);
        }
        // we've filled strRep, we now attach it to the event
        return new ThrowableInformation(strRep);
      } finally {
        if (statement != null) {
          statement.close();
        }
      }
    }
docs: Retrieve the exception string representation from the
  logging_event_exception table.
  
  @param connection
  @param id
  @throws SQLException