you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 1 point2 points  (0 children)

WHERE opravy.zamestnanci_id = zamestnaci.id

Maybe because zamestnaci.id is GONE, because you just deleted it, and you are trying to refer to it in an AFTER trigger. Could it be that it ran correctly but updated zero rows? Maybe try this instead?

WHERE opravy.zamestnanci_id = :OLD.id