doctrine2 - Symfony, ManyToMany refers to the owning side field which does not exist -


i have @manytomany relation 2 entities.

i have (short code)

class photo {      /**     * @orm\manytomany(targetentity="application\sonata\userbundle\entity\user", mappedby="photos")     */     protected $users; }  class user {      /**     * @orm\manytomany(targetentity="mybundle\photobundle\entity\photo", inversedby="users", cascade={"persist"})     * @orm\jointable(name="user_photos")     */     protected $photos; }   php app/console doctrine:schema:validate -> [mapping]  fail - entity-class 'mybundle\photobundle\entity\photo' mapping invalid: * association mybundle\photobundle\entity\photo#users refers owning side field application\sonata\userbundle\entity\user#photos not exist. 

i looked in stack , try somethings still have problem.

sonatauserbundle using xml entities. can't use annotations relation.


Comments

Popular posts from this blog

java - Plugin org.apache.maven.plugins:maven-install-plugin:2.4 or one of its dependencies could not be resolved -

Round ImageView Android -

How can I utilize Yahoo Weather API in android -