I have 2 tables. Days and Parameters . In the first table - id , days (int). In the second table - id , param (int), daysId (int). daysId - key from the first table. It is necessary to remove data from the first table, where days <90, but also also need to remove parameters from the second table that are bound to the deleted data by daysId . How can I link 2 tables in a delete query?
In my tables there are more columns, I gave a minimal example.
daysId- is the key from the first FK table available? Create and install ON DELETE CASCADE - it will go away by itself ... - Akina