mirror of
https://github.com/doctrine/orm.git
synced 2026-03-23 22:42:18 +01:00
DDC-380: Bug in persisting entity #473
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 (Feb 26, 2010).
Originally assigned to: @beberlei on GitHub.
Jira issue originally created by user quest:
Maybe I found a small bug.
Following hierarchy:
Class1 extends a mapped superclass
Class2 extends Class1
createdBy is an attribute of the mapped superclass.
Persisting an object of class1 works fine.
Persisting an object of class2 results in this error:
Fatal error: Uncaught exception 'PDOException' with message
'SQLSTATE[42S22]: Column not found: 1054 Unknown column 'createdBy' in
'field list''
Best thing of this error: This column exists in database!
I fetched the SQL-command that is used here by adding
echo $stmt->queryString . "
";
to Doctrine/orm/persisters/StandardEntityPersister.php line 173
Last output before error:
INSERT INTO Menu (name, slug, title, created, createdBy, updated,
updatedBy, updatedReason, panel, contenttext, active, published,
menuType) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
As said before, all these columns exist in table Menu.
@doctrinebot commented on GitHub (Feb 26, 2010):
Comment created by @beberlei:
Thank you for reporting this issue.
Please create a unit-test, in the schema of tests\Doctrine\Tests\ORM\Functional\Ticket with entities and a failing test-case and attach it as a .patch or .diff or .php file.
@doctrinebot commented on GitHub (Mar 20, 2010):
Comment created by @beberlei:
I need another information, what type of inheritance type is defined for Class1 <-> Class2 Relationship?
Can you give a mapping example for your case?
@doctrinebot commented on GitHub (Mar 28, 2010):
Comment created by @beberlei:
Cannot reproduce this issue without further information, downgrading issue priority and timeframe.
@doctrinebot commented on GitHub (Jul 28, 2010):
Comment created by @beberlei:
Closed, no further user input was given.
@doctrinebot commented on GitHub (Jul 28, 2010):
Issue was closed with resolution "Incomplete"