InvariantViolationException¶
InvariantViolationException is a RuntimeException (Java) that is reported when data does not match the rules of a table (using Constraints).
Creating Instance¶
InvariantViolationException takes the following to be created:
- Error Message
InvariantViolationException is created when:
DeltaErrorsutility is used to notNullColumnMissingExceptionInvariantViolationExceptionutility is used to apply
Creating InvariantViolationException¶
apply creates a InvariantViolationException for the given constraint: Check or NotNull.
Check¶
apply(
constraint: Constraints.Check,
values: Map[String, Any]): InvariantViolationException
CHECK constraint [name] [sql] violated by row with values:
- [column] : [value]
NotNull¶
apply(
constraint: Constraints.NotNull): InvariantViolationException
NOT NULL constraint violated for column: [name]
Usage¶
apply is used when:
CheckDeltaInvariantis used to eval (and assertRule)