please can someone tell me how can I set onDelete: SetNull in Symfony 2? Here is example:
oneToOne:
Company:
targetEntity: Company
inversedBy: id
joinColumn:
name: id
referencedColumnName: contact_person
onDelete: ??
Thanks.
Just quote the string and set onDelete
to SET NULL
like this:
joinColumn:
onDelete: "SET NULL"
more options: http://www.doctrine-project.org/jira/browse/DDC-409
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With