I am using doctrine and codeigniter and I have an existing db.this tool supposedly enables generating models from a database.
I try :
php doctrine.php orm:convert-mapping --from-database
But I get a Runtime exception (NOt enough arguments)
any ideas?
Try like this,
For the XML output
php doctrine orm:convert-mapping --from-database --namespace='Entities\' xml mapping/xml
For the YAML output
php doctrine orm:convert-mapping --from-database --namespace='Entities\' yml mapping/yml
After that you should create entities like this,
php doctrine orm:generate-entities
Help,
php doctrine orm:generate-entities --help
For the more information, docs
You missed some arguments like project full path
php doctrine orm:convert-mapping --namespace='Entities\' --force --from-database annotation your/project/full/path
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With