Package java.sql

Examples of java.sql.BatchUpdateException.initCause()


        // while using the Java 8 constructor
        BatchUpdateException batch = new BatchUpdateException
            ( message, sqlState, errorCode, squashLongs( updateCounts ) );
       
        if ( cause instanceof SQLException ) { batch.setNextException( (SQLException) cause ); }
        batch.initCause( cause );

        return batch;
    }

    /** Squash an array of longs into an array of ints */
 
View Full Code Here


          newUpdateCounts, 0, endOfBatchIndex);

      BatchUpdateException batchException = new BatchUpdateException(ex
          .getMessage(), ex.getSQLState(), ex
          .getErrorCode(), newUpdateCounts);
      batchException.initCause(ex);
      throw batchException;
    }
   
    return sqlEx;
  }
View Full Code Here

        // while using the Java 8 constructor
        BatchUpdateException batch = new BatchUpdateException
            ( message, sqlState, errorCode, squashLongs( updateCounts ) );
       
        if ( cause instanceof SQLException ) { batch.setNextException( (SQLException) cause ); }
        batch.initCause( cause );

        return batch;
    }

    /** Squash an array of longs into an array of ints */
 
View Full Code Here

    {
        BatchUpdateException bue = new BatchUpdateException
            ( message, sqlState, errorCode, Utils.squashLongs( updateCounts ) );

        if (cause != null) {
            bue.initCause(cause);
        }

        return bue;
    }
}
View Full Code Here

          newUpdateCounts, 0, endOfBatchIndex);

      BatchUpdateException batchException = new BatchUpdateException(ex
          .getMessage(), ex.getSQLState(), ex
          .getErrorCode(), newUpdateCounts);
      batchException.initCause(ex);
      throw batchException;
    }
   
    return sqlEx;
  }
View Full Code Here

        // while using the Java 8 constructor
        BatchUpdateException batch = new BatchUpdateException
            ( message, sqlState, errorCode, squashLongs( updateCounts ) );
       
        if ( cause instanceof SQLException ) { batch.setNextException( (SQLException) cause ); }
        batch.initCause( cause );

        return batch;
    }

    /** Squash an array of longs into an array of ints */
 
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.