Mistake
Cannot delete or update parent row: foreign key constraint fails.
Classes
class Teacher { protected $publications; } class Publication { protected $teacher; }
I want to
I want to make the id_teacher change to NULL when the teacher is deleted. I want to keep the publication, but without reference to the professor.
I do not know how this is done in the Doctrine, is this possible? Or should the relationship always be with the teacher?
set null doctrine one-to-many
Nicolas Lino Jan 13 '12 at 23:29 2012-01-13 23:29
source share