1
0
mirror of synced 2024-12-15 07:36:03 +03:00
doctrine2/manual/docs/Working with objects - Dealing with relations - Deleting related records.php
2007-04-13 21:49:11 +00:00

13 lines
307 B
PHP

You can delete related records individually be calling delete() on each record. If you want to delete a whole record graph just call
delete on the owner record.
<code type="php">
$user->Email->delete();
$user->Phonenumber[3]->delete();
// deleting user and all related objects:
$user->delete();
</code>