All pastes #347907 Raw Edit

Unnamed

public text v1 · immutable
·published 2007-02-09 20:04 UTC
rendered paste body
  public List getList(String statementName, Object parameterObject) throws DaoException {
    List list = null;
    SqlMapClient sqlMap2 = ThreadLocalSqlMapClient.getSqlMapClient();
    
    try {
      sqlMap2.startTransaction();
      list = sqlMap2.queryForList(statementName, parameterObject);
      sqlMap2.commitTransaction();
    } catch (SQLException e) {
      try {
        sqlMap2.endTransaction();
      } catch (SQLException ex) {
        throw new DaoException(ex.fillInStackTrace());
      }
      throw new DaoException(e.fillInStackTrace());
    } finally {
      try {
        sqlMap2.endTransaction();
      } catch(SQLException sqle) {}
    }
    return list;
  }