CHECK_CONSTRAINTS
Applies to: Databricks SQL
Databricks Runtime
Unity Catalog only
Reserved for future use.
INFORMATION_SCHEMA.CHECK_CONSTRAINTS will describe check constraints defined on tables.
Definition
The CHECK_CONSTRAINTS
relation contains the following columns:
Name | Data type | Nullable | Standard | Description |
---|---|---|---|---|
|
| No | Yes | Catalog containing the check constraint. |
|
| No | Yes | Schema containing the check constraint. |
|
| No | Yes | Name of the check constraint. |
|
| No | Yes | The text of the check constraint condition. |
|
| No | Yes | Always |
Constraints
The following constraints apply to the CHECK_CONSTRAINT
relation:
Class | Name | Column List | Description |
---|---|---|---|
Primary key |
|
| Unique identifier for the constraint. |
Foreign key |
|
| References TABLE_CONSTRAINTS. |
Examples
> SELECT constraint_name, check_clause
FROM information_schema.check_constraints
WHERE table_schema = 'information_schema';