0

There is a way (also presented here) to have create Eloquent ORM Models (as a part of a Laravel app) based on a database.

I am looking for the inverse action. I would like to write some Eloquent Model classes and have them being craeted as tables in the database.

How can this be done?

This Eloquent documentation does not feature any information. Can it be that while there is a often the case 1-to-1-mapping between the database and the eleoquent models a table canno tbe created automatically given a Eloquent Model was provided?

humanityANDpeace
  • 4,350
  • 3
  • 37
  • 63
  • Use already answered questions [link](https://stackoverflow.com/questions/30560485/create-models-from-database-in-laravel-5) Hope it helps – salman faris Oct 13 '19 at 14:06
  • @salmanfaris not really. I attempt to do the reverse, I have models and want to create the database content (i.e. have tables created to fit the models coded). The link you included in the comment has been already mentioned in my question, as an example to which I seek the **inverse** action to. thanks ! – humanityANDpeace Oct 13 '19 at 14:10
  • https://stackoverflow.com/questions/30096105/laravel-creating-tables-dynamically-without-migration – salman faris Oct 13 '19 at 14:12

0 Answers0