Answer the question
In order to leave comments, you need to log in
Entity generation from symfony 4 ready database?
Hello everyone, the question is how to generate entities from a ready-made database, yes, there are 2 tables in the database
symfony 4 is installed with its new file structure, orm-pack and maker-bundle are installed in the components
I can’t figure out how to generate entities for myself, based on the finished database structure.
Don't forget to read the footnote at the top of the article for version 4 if you send me here
. So who can help?
Answer the question
In order to leave comments, you need to log in
I will send you here
https://github.com/doctrine/DoctrineBundle/issues/...
php bin/console doctrine:mapping:convert --from-database annotation ./src/Entity
There is a solution on the link below:
1) create a symfony 3.3 installation
2) doctrine:mapping:import from existing database
3) copy and paste Entity files in my new symfony 4 project (after change "AppBundle" with "App" in each one)
4) doctrine:schema: update --force in new symfony 4 project
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question