private void dropIndex(String indexName) throws OracleException {
  PreparedStatement stmt=null;
  if (indexName == null)   throw SODAUtils.makeException(SODAMessage.EX_ARG_CANNOT_BE_NULL,"indexName");
  indexName=CollectionDescriptor.stringToIdentifier(indexName);
  String sqltext=dropIndexDDL(indexName);
  try {
    metrics.startTiming();
    stmt=conn.prepareStatement(sqltext);
    stmt.execute();
    if (OracleLog.isLoggingEnabled())     log.info("Dropped index " + indexName);
    stmt.close();
    stmt=null;
    metrics.recordDDL();
  }
 catch (  SQLException e) {
    int errcode=e.getErrorCode();
    if ((errcode == ORA_SQL_OBJECT_NOT_EXISTS) || (errcode == ORA_SQL_INDEX_NOT_EXISTS)) {
      if (OracleLog.isLoggingEnabled())       log.warning(e.toString());
    }
 else {
      if (OracleLog.isLoggingEnabled())       log.warning(e.toString());
      throw SODAUtils.makeExceptionWithSQLText(e,sqltext);
    }
  }
 finally {
    for (    String message : SODAUtils.closeCursor(stmt,null)) {
      if (OracleLog.isLoggingEnabled())       log.severe(message);
    }
  }
}

private void dropIndex ( String indexName ) throws OracleException { PreparedStatement stmt = null ; if ( indexName == null ) throw SODAUtils . makeException ( SODAMessage . EX_ARG_CANNOT_BE_NULL , "indexName" ) ; indexName = CollectionDescriptor . stringToIdentifier ( indexName ) ; String sqltext = dropIndexDDL ( indexName ) ; try { metrics . startTiming ( ) ; stmt = conn . prepareStatement ( sqltext ) ; stmt . execute ( ) ; if ( OracleLog . isLoggingEnabled ( ) ) log . info ( "Dropped index " + indexName ) ; stmt . close ( ) ; stmt = null ; metrics . recordDDL ( ) ; } catch ( SQLException e ) { int errcode = e . getErrorCode ( ) ; if ( ( errcode == ORA_SQL_OBJECT_NOT_EXISTS ) || ( errcode == ORA_SQL_INDEX_NOT_EXISTS ) ) { if ( OracleLog . isLoggingEnabled ( ) ) log . warning ( e . toString ( ) ) ; } else { if ( OracleLog . isLoggingEnabled ( ) ) log . warning ( e . toString ( ) ) ; throw SODAUtils . makeExceptionWithSQLText ( e , sqltext ) ; } } finally { for ( String message : SODAUtils . closeCursor ( stmt , null ) ) { if ( OracleLog . isLoggingEnabled ( ) ) log . severe ( message ) ; } } }
drop the named index
