MySQL Workbench To Laravel Migration
We all have our favourite database GUIs, some work with PHPMyAdmin others use tools such as MySQL Workbench. I tend to use MySQL Workbench more than any database GUI tool.
MySQL Workbench is a cross-platform GPL app that allows you to fully design and document your databases through the app.
Recently I've discovered this plugin for workbench that allows you to export a table into Laravel Migration classes.
A MySQL Workbench plugin that allows for exporting a model to Laravel 5 migrations that follow PSR-2 coding standards. When exported, each migration is generated and saved in it's own, properly named, migration file.
- MySQL Workbench > Scripting > Install Plugin/Module
- Select the plugin file
- Click Open
- Open a model in MySQL Workbench
- Tools > Catalog > Export Laravel 5 Migration
Now you can copy this migration file into your Laravel project, this allows you to build up your database in MySQL workbench and when you're done export the database into your Laravel migration files.
Gain access to all tutorials
- Premium tutorials covering WordPress, Laravel and VueJS
- Download premium content
- Download premium WordPress plugins
- Only $5 a month
Join the weekly newsletter
Sign up for our newsletter. You'll be updated on new tutorials as they come available.