title: CASCADE Delete in many-to-many self-reference table
body: <p>Table <strong>DISPLAY_TAB</strong> below is a self-reference table that can contain both parent and child tabs. A parent tab can have multiple child tabs and a child tab can belong to multiple parents. </p>
  
  <p>I'd like to establish a CASCADE DELETE relationship between main table and relationship table <strong>DISPLAY_TAB_GROUPING</strong> so when either parent or child tab is deleted - relationship is automatically deleted as well (just relationship, not actual tab record). So I am creating a FOREIGN KEY constrain on <strong>DISPLAY_TAB_GROUPING</strong> for fields TAB_ID_R_1 and TAB_ID_R_2 tables, referencing TAB_ID in <strong>DISPLAY_TAB</strong> table. And it works fine, it works fine when I add ON DELETE CASCADE for one of the relationship, but when I try it for both - it throws an error that this <em>"May cause cycles or multiple cascade paths"</em>.</p>
  
  <p>How do I set ON CASCADE DELETE for both relationships? I don't see how this can cause cycles - every time a record in main table is deleted only related record(s) in relationship tables should be deleted.</p>
  
  <p><img src="https://i.stack.imgur.com/7v77J.png" alt="enter image description here"></p>