mirror of
https://github.com/doctrine/orm.git
synced 2026-03-23 22:42:18 +01:00
After the dynamic meta data change (with code) Entity SQLs not building again and using old meta data 's SQLs for operations. #6611
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 @mdogancay on GitHub (Jan 20, 2021).
Hi,
After the
$metadata->setPrimaryTable()or$metadata->setTableName()function calls; doctrine not doing reparse the Entity meta data and rebuild the SQLs for this entity. for example:That code always add both records to 'first_cat_product' table. Second meta data change ignoring.
Doctrine MUST reparse or rebuild the related SQLs after the meta data change for an Entity.
Otherwise meta data modification functions have no meaning.
@beberlei commented on GitHub (Feb 7, 2021):
Its not allowed to change metadata at runtime, only in MappingDriver and loadMetadata event