I have two related tables to create a grid.
When I delete a record in the grid, only the record of one of the tables is deleted.
How to also delete the related record in the other table?
Thanks for your help.
This is the relationship
$g->select_command = "SELECT * FROM ( SELECT
LEFT(CONCAT(r.nombre, ' ', r.apellidos),20) as nombre_t,
SUBSTRING($campo_semana,2,21) as semana,
if((r.regimen = 0 OR r.regimen =''),'', r.regimen) AS regimen_final,
FROM residentes r
INNER JOIN comidas c
ON c.sala_comida = r.sala
I delete the record of the "residents" table, but not delete the corresponding record in the table "comidas"
We are sorry that this post was not useful for you!
Let us improve this post!
Tell us how we can improve this post?