You can manually add primary keys and foreign keys to tables to establish relationships between tables for data subset operations. When you manually add keys, you do not need to run a primary key discovery profile.
When you add keys, you define constraints for data subset, data masking, and data generation operations in the project. You do not update the source database.
You can add the following types of keys constraints:
Primary Key
You can add one column or column combination as the primary key for a table. A primary key column cannot contain null or duplicate values. You cannot add more than one primary key constraint.
Foreign Key
Add a column or column combination as a foreign key in a table. When you define a constraint, you define a foreign key in a table and relate it to a column in a parent table.
Unique Key
Add a column or set of columns as a constraint to define a unique key in a table. A unique key column can contain null values. You can create more than one unique key in table. You can perform multiple data generation assignments when you filter the columns based on unique keys.
Conditional
Add a conditional constraint to perform a data generation operation. Create a conditional constraint to restrict the data that you want to generate in a column based on the data in another column. The conditional constraint that you enter becomes a part of the metadata of the target table. Configure expressions to apply constraints at the table level.