defmodule ActionRequestsDemo.Repo.Migrations.CreateActionRequests do use Ecto.Migration def change do create table(:action_requests, primary_key: false) do add :id, :binary_id, primary_key: true add :patient_name, :string add :status, :string add :assigned_user_id, :integer add :delivery_scheduled_at, :naive_datetime timestamps(type: :utc_datetime) end create index(:action_requests, [:patient_name]) create index(:action_requests, [:status]) create index(:action_requests, [:assigned_user_id]) create index(:action_requests, [:inserted_at]) end end