Skip to main content


Suppress/return error upon ADD a foreign key, when a key of that name already exists.


[SQL]    DDLNo311=n


The value n may be 1 or 0:

  • If 1 (true) when an attempt is made to ADD a foreign key, even if a key of that name already exists, Caché suppresses the SQLCODE -311 error.

  • If 0 (false) Caché returns the error.



Range of Values

0 or 1. The default is 0.

Management Portal

On the page System Administration > Configuration > SQL and Object Settings > General SQL Settings, for the Allow DDL ADD Foreign Key Constraint when Foreign Key Exists setting, choose Yes (true) or No (false).

FeedbackOpens in a new tab