Annotation Type CheckConstraint


  • @Target({})
    @Retention(RUNTIME)
    public @interface CheckConstraint
    Used to specify a SQL check constraint on a column or table when schema generation is in effect.
    Since:
    3.2
    See Also:
    Table.check(), Column.check()
    • Required Element Summary

      Required Elements 
      Modifier and Type Required Element Description
      java.lang.String constraint
      (Required) The native SQL expression to be checked.
    • Optional Element Summary

      Optional Elements 
      Modifier and Type Optional Element Description
      java.lang.String name
      (Optional) The name of the constraint.
      java.lang.String options
      (Optional) A SQL fragment appended to the generated DDL which creates this constraint.
    • Element Detail

      • constraint

        java.lang.String constraint
        (Required) The native SQL expression to be checked.
      • name

        java.lang.String name
        (Optional) The name of the constraint.

        Defaults to a provider-generated name.

        Default:
        ""
      • options

        java.lang.String options
        (Optional) A SQL fragment appended to the generated DDL which creates this constraint.
        Since:
        3.2
        Default:
        ""