[Progress Communities] [Progress OpenEdge ABL] Forum Post: RE: How to add a FOREIGN KEY to an existing table?

  • Thread starter Thread starter YerAmil
  • Start date Start date
Status
Not open for further replies.
Y

YerAmil

Guest
Ok. Thank you all for answers. But I am little confused. Judging by this article, this is possible, but only need to be sure that the table columns chosen as primary or foreign key do not accept NULL values by making them mandatory. There also use the PUB scheme in the example. knowledgebase.progress.com/.../SQL-command-to-add-a-FOREIGN-KEY-constraint-to-an-existing-table-fails-with-the-error-7545 From this article I conclude that it is still possible at the SQL level. Am I wrong again? If I'm wrong, what is this article for? It is a bug? Where it is a bug, in the article or in my code above? Ok. Suppose the use of FK is not possible in OpenEdge at the SQL level. At the OpenEdge ABL level to implement something like referential integrity I have to write an ABL procedure for the trigger to delete, create, etc. Right? But it is inconvenient for database exploitation: 1. The ABL trigger is not part of the database and must be stored separately in the file system. 2. The ABL code of the trigger can be illegally replaced by someone. Then we will not know that this code has been changed. Is'n it? 3. From ABL, someone can programmatically disable triggers using the DISABLE TRIGGERS statement. Right? 4. ABL triggers do not cover SQL operations. Right? How to ensure referential integrity at the SQL level in OpenEdge?

Continue reading...
 
Status
Not open for further replies.
Back
Top