@OvermindDL1, thanks for mentioning!
I made it for database schema migration:
defmodule App.Repo.Migrations.CreateSchema do
use Ecto.Migration
@schema_prefix Application.fetch_env!(:app, :schema_prefix)
def up do
execute "create schema #{@schema_prefix}"
end
def down do
execute "drop schema #{@schema_prefix}"
end
end
With FK, I guess it will be dropped with table during rollback.