13 lines
285 B
Elixir
13 lines
285 B
Elixir
defmodule Core.Repo.Migrations.AddPostsTable do
|
|
use Ecto.Migration
|
|
|
|
def change do
|
|
create table(:posts, primary_key: false) do
|
|
add :id, :uuid, primary_key: true
|
|
add :title, :text
|
|
add :body, :text, null: false, default: ""
|
|
|
|
timestamps()
|
|
end
|
|
end
|
|
end
|