mirror of
https://github.com/zoldar/jenot.git
synced 2026-01-03 14:32:54 +00:00
16 lines
354 B
Elixir
16 lines
354 B
Elixir
defmodule Jenot.Repo.Migrations.AddDefaultAccount do
|
|
use Ecto.Migration
|
|
|
|
def change do
|
|
id = Ecto.UUID.generate()
|
|
now = DateTime.utc_now() |> DateTime.to_iso8601()
|
|
|
|
execute """
|
|
INSERT INTO accounts (id, inserted_at, updated_at)
|
|
VALUES ('#{id}', '#{now}', '#{now}')
|
|
""",
|
|
"""
|
|
DELETE FROM accounts
|
|
"""
|
|
end
|
|
end
|