defmodule DaProductApp.Repo.Migrations.CreateProviders do use Ecto.Migration def change do create table(:providers) do add :name, :string, null: false add :status, :string, null: false, default: "active" add :production_url, :string add :production_mode, :boolean, default: false, null: false add :description, :text timestamps(type: :utc_datetime) end create unique_index(:providers, [:name]) create index(:providers, [:status]) end end