mirror of
https://github.com/doctrine/orm.git
synced 2026-03-24 06:52:09 +01:00
DDC-3271: Impossible to set-up Two relations one-to-one which share the same target #4047
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @doctrinebot on GitHub (Aug 25, 2014).
Originally assigned to: @Ocramius on GitHub.
Jira issue originally created by user lyrixx:
I reproduced my issue in a SF2 standard edition.
https://github.com/lyrixx/symfony-standard/blob/doctrine-many/test.php
So basically:
I have a "dude" table, with 2 FK: "delivery_address" and "billing_address".
But I'm not able to set-up doctrine to make it work, because when I set-up
the "Address" Entity, doctrine add a "unique" constraint on this table.
So I can insert one of the two addresses, but not two addresses.
@doctrinebot commented on GitHub (Oct 19, 2014):
Comment created by @ocramius:
This is actually how one-to-one works: you are probably looking for a different association type here.
@doctrinebot commented on GitHub (Oct 19, 2014):
Issue was closed with resolution "Won't Fix"