Package org.hibernate

Examples of org.hibernate.JDBCException


  }

  @Override
  public JDBCException convert(SQLException sqlException, String message, String sql) {
    for ( SQLExceptionConversionDelegate delegate : delegates ) {
      final JDBCException jdbcException = delegate.convert( sqlException, message, sql );
      if ( jdbcException != null ) {
        return jdbcException;
      }
    }
    return new GenericJDBCException( message, sqlException, sql );
View Full Code Here


          }
        }
        catch ( SQLException e ) {
          if (!script.isQuiet()) {
            if ( haltOnError ) {
              throw new JDBCException( "Error during DDL export", e );
            }
            exceptions.add( e );
                      LOG.unsuccessful(script.getScript());
                      LOG.error(e.getMessage());
          }
View Full Code Here

  public final Dialect resolveDialect(DatabaseMetaData metaData) {
    try {
      return resolveDialectInternal( metaData );
    }
    catch ( SQLException sqlException ) {
      JDBCException jdbcException = BasicSQLExceptionConverter.INSTANCE.convert( sqlException );
            if (jdbcException instanceof JDBCConnectionException) {
        throw jdbcException;
      }

            LOG.warnf( "%s : %s", BasicSQLExceptionConverter.MSG, sqlException.getMessage() );
View Full Code Here

            stmt.executeUpdate( formatted );
          }
        }
        catch ( SQLException e ) {
          if ( haltOnError ) {
            throw new JDBCException( "Error during DDL export", e );
          }
          exceptions.add( e );
                    LOG.unsuccessful(sql);
                    LOG.error(e.getMessage());
        }
View Full Code Here

  public final Dialect resolveDialect(DatabaseMetaData metaData) {
    try {
      return resolveDialectInternal( metaData );
    }
    catch ( SQLException sqlException ) {
      final JDBCException jdbcException = BasicSQLExceptionConverter.INSTANCE.convert( sqlException );
      if (jdbcException instanceof JDBCConnectionException) {
        throw jdbcException;
      }

      LOG.warnf( "%s : %s", BasicSQLExceptionConverter.MSG, sqlException.getMessage() );
View Full Code Here

        session.getBatcher().closeStatement( st );
      }

    }
    catch ( SQLException sqle ) {
      JDBCException e = JDBCExceptionHelper.convert(
          session.getFactory().getSQLExceptionConverter(),
          sqle,
          "could not lock: " + MessageHelper.infoString( lockable, id, session.getFactory() ),
          sql
        );
View Full Code Here

        session.getBatcher().closeStatement( st );
      }

    }
    catch ( SQLException sqle ) {
      JDBCException e = JDBCExceptionHelper.convert(
          session.getFactory().getSQLExceptionConverter(),
          sqle,
          "could not lock: " + MessageHelper.infoString( lockable, id, session.getFactory() ),
          sql
        );
View Full Code Here

          }
        }
        catch ( SQLException e ) {
          if (!script.isQuiet()) {
            if ( haltOnError ) {
              throw new JDBCException( "Error during DDL export", e );
            }
            exceptions.add( e );
                      LOG.unsuccessful(script.getScript());
                      LOG.error(e.getMessage());
          }
View Full Code Here

            stmt.executeUpdate( formatted );
          }
        }
        catch ( SQLException e ) {
          if ( haltOnError ) {
            throw new JDBCException( "Error during DDL export", e );
          }
          exceptions.add( e );
                    LOG.unsuccessful(sql);
                    LOG.error(e.getMessage());
        }
View Full Code Here

      Blob blob = createBlob();
      blob.setBytes( 1, bytes );
      return blob;
    }
    catch ( SQLException e ) {
      throw new JDBCException( "Unable to set BLOB bytes after creation", e );
    }
  }
View Full Code Here

TOP

Related Classes of org.hibernate.JDBCException

Copyright © 2018 www.massapicom. 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.