DDC-2886: Entity of Base class in STI can't be persisted because of discriminator column isn't nullable #3601

Closed
opened 2026-01-22 14:23:34 +01:00 by admin · 4 comments
Owner

Originally created by @doctrinebot on GitHub (Jan 5, 2014).

Originally assigned to: @beberlei on GitHub.

Jira issue originally created by user usver:

When using single table inheritance, discriminator field doesn't created as nullable... so when you persist Base class.. it has null value and you get MySQL violation

Originally created by @doctrinebot on GitHub (Jan 5, 2014). Originally assigned to: @beberlei on GitHub. Jira issue originally created by user usver: When using single table inheritance, discriminator field doesn't created as nullable... so when you persist Base class.. it has null value and you get MySQL violation
admin added the Bug label 2026-01-22 14:23:34 +01:00
admin closed this issue 2026-01-22 14:23:34 +01:00
Author
Owner

@doctrinebot commented on GitHub (Jan 5, 2014):

Comment created by usver:

Some code for this issue
https://gist.github.com/USvER/d1699c75ec687b4587da

@doctrinebot commented on GitHub (Jan 5, 2014): Comment created by usver: Some code for this issue https://gist.github.com/USvER/d1699c75ec687b4587da
Author
Owner

@doctrinebot commented on GitHub (Jan 5, 2014):

Comment created by usver:

As was pointed out by Bittarman on IRC, base class was not included in DiscriminatorMap...
Closing as not an issue

@doctrinebot commented on GitHub (Jan 5, 2014): Comment created by usver: As was pointed out by Bittarman on IRC, base class was not included in DiscriminatorMap... Closing as not an issue
Author
Owner

@doctrinebot commented on GitHub (Jan 5, 2014):

Comment created by usver:

Not an issue

@doctrinebot commented on GitHub (Jan 5, 2014): Comment created by usver: Not an issue
Author
Owner

@doctrinebot commented on GitHub (Jan 5, 2014):

Issue was closed with resolution "Invalid"

@doctrinebot commented on GitHub (Jan 5, 2014): Issue was closed with resolution "Invalid"
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: doctrine/archived-orm#3601