DDC-3568: Discriminator column in joined multiple inheritance #4387

Open
opened 2026-01-22 14:40:45 +01:00 by admin · 0 comments
Owner

Originally created by @doctrinebot on GitHub (Feb 16, 2015).

Originally assigned to: @Ocramius on GitHub.

Jira issue originally created by user anooxy:

I'm facing an issue when trying to use multiple inheritance via discriminators. When generating a schema, only the superclass has a discriminator column.

See my test case: https://github.com/anooxy/doctrine-multiple-inheritance-test

The hierarchy is supposed to be (inheriting order):

TutorContact -> TutorStudentChildrenContact -> Contact
StudentContact -> StudentChildrenContact -> TutorStudentChildrenContact & StudentParentContact -> Contact
ParentContact -> StudentParentContact -> Contact
ChildrenContact -> StudentChildrenContact -> TutorStudentChildrenContact -> Contact

Only Contact table has a discriminator column, whereas the middle tables, which have been assigned a discriminator in the annotations, do not have one.

Originally created by @doctrinebot on GitHub (Feb 16, 2015). Originally assigned to: @Ocramius on GitHub. Jira issue originally created by user anooxy: I'm facing an issue when trying to use multiple inheritance via discriminators. When generating a schema, only the superclass has a discriminator column. See my test case: https://github.com/anooxy/doctrine-multiple-inheritance-test The hierarchy is supposed to be (inheriting order): TutorContact -> TutorStudentChildrenContact -> Contact StudentContact -> StudentChildrenContact -> TutorStudentChildrenContact & StudentParentContact -> Contact ParentContact -> StudentParentContact -> Contact ChildrenContact -> StudentChildrenContact -> TutorStudentChildrenContact -> Contact Only Contact table has a discriminator column, whereas the middle tables, which have been assigned a discriminator in the annotations, do not have one.
admin added the Bug label 2026-01-22 14:40:45 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: doctrine/archived-orm#4387