Answer the question
In order to leave comments, you need to log in
Error when creating a new instance of an inherited entity in Symfony2?
There is a Page entity, everything is ok with it: instances are created.
Created the Good entity, class Good extends Page
added a couple of additional fields to it and inherited the constructor from the parent
public function __construct()
{
parent::__construct();
}
$resolver->setDefaults(array(
'data_class' => 'alkr\ShopBundle\Entity\Good'
));
An exception occurred while executing 'SELECT p0_.path AS path_0, p0_.id AS id_1, p0_.prior AS prior_2, p0_.url AS url_3, p0_.enabled AS enabled_4, p0_.feedback AS feedback_5, p0_.map AS map_6, p0_.lvl AS lvl_7, p0_.lastmod AS lastmod_8, p0_.view AS view_9, p0_.annotation AS annotation_10, p0_.content AS content_11, p0_.title AS title_12, p0_.metaTitle AS metaTitle_13, p0_.menuTitle AS menuTitle_14, p0_.keywords AS keywords_15, p0_.description AS description_16, g1_.price AS price_17, g1_.amount AS amount_18, p0_.parent_id AS parent_id_19, p0_.preview AS preview_20 FROM Good g1_ ORDER BY g1_.path ASC':
SQLSTATE[42S22]: Column not found: 1054 Unknown column 'p0_.path' in 'field list'
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question