Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Reverse engineering doctrine

Doctrine Reverse Engineering

Doctrine Source

How to create Entity files from database tables?

1. Creating .orm.yml files in /Resources/config/...

php app/console doctrine:mapping:import --force AcmeBlogBundle yml --env=prod

You can also use xml. For example: I had to use SiesqoPlusMakerBundle

2. Creating the Entity files

# This command will generate entity classes with annotation mappings
php app/console doctrine:mapping:convert annotation ./src --env=prod

# But if you want to use YAML or XML mapping instead of annotations, you should only execute this command.
php app/console doctrine:generate:entities AcmeBlogBundle
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.