Using Ecto With an Existing MySQL Database
While Postgres is the default Ecto database type, you can use MySQL databases as well. Beyond that, it is relatively easy to connect to an already existing MySQL database and take advantage of the power of Ecto with it.
In this post we discover how to connect to an already existing MySQL database and even deal with non-standard field types and funky primary keys.
http://geoffreylessel.com/2016/using-ecto-with-an-existing-mysql-database/
Read next Phoenix vs Rails: Mix and Rake tasks