phoenix-framework Ecto models usage in phoenix Migrations of ecto model


When you run mix phoenix.gen.html or mix phoenix.gen.json from command line, migrations are created in priv -> repo -> migrations in your project folder.

To run migrations type mix ecto.migrate.

To generate migrations for your project mix ecto.gen migrations <model_name>

To generate migrations for a different repository than default one run mix ecto.gen migrations <model_name> -r <repo_name>