Skip to content

Commit 4583fbd

Browse files
committed
Document that Doctrine associations don't work across different entity managers
1 parent c60a234 commit 4583fbd

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

doctrine/multiple_entity_managers.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,12 @@ entity manager that connects to another database might handle the rest.
1616
usually required. Be sure you actually need multiple entity managers before
1717
adding in this layer of complexity.
1818

19+
.. caution::
20+
21+
Entities cannot define associations across different entity managers. If you
22+
need that, there are `several alternatives <https://stackoverflow.com/a/11494543/2804294>`_
23+
that require some custom setup.
24+
1925
The following configuration code shows how you can configure two entity managers:
2026

2127
.. configuration-block::

0 commit comments

Comments
 (0)