如果要查看某个表定义的约束情况,可以使用以下语句:
SELECT constraint_name, constraint_type,
search_condition
FROM user_constraints
WHERE table_name = tab_name;
查询表中的列约束情况:
SELECT constraint_name, column_name
FROM user_cons_columns
WHERE table_name = 'EMPLOYEES';