FileDocCategorySizeDatePackage
ConstraintViolationException.javaAPI DocHibernate 3.2.51019Sat Nov 20 17:11:28 GMT 2004org.hibernate.exception

ConstraintViolationException

public class ConstraintViolationException extends org.hibernate.JDBCException
Implementation of JDBCException indicating that the requested DML operation resulted in a violation of a defined integrity constraint.
author
Steve Ebersole

Fields Summary
private String
constraintName
Constructors Summary
public ConstraintViolationException(String message, SQLException root, String constraintName)

		super( message, root );
		this.constraintName = constraintName;
	
public ConstraintViolationException(String message, SQLException root, String sql, String constraintName)

		super( message, root, sql );
		this.constraintName = constraintName;
	
Methods Summary
public java.lang.StringgetConstraintName()
Returns the name of the violated constraint, if known.

return
The name of the violated constraint, or null if not known.

		return constraintName;