mirror of
https://github.com/plausible/analytics.git
synced 2024-12-18 23:11:43 +03:00
24 lines
599 B
Elixir
24 lines
599 B
Elixir
defmodule Plausible.Repo.Migrations.AddSessions do
|
|
use Ecto.Migration
|
|
|
|
def change do
|
|
create table(:sessions) do
|
|
add :hostname, :text, null: false
|
|
add :new_visitor, :boolean, null: false
|
|
add :user_id, :binary_id, null: false
|
|
|
|
add :is_bounce, :boolean, null: false
|
|
add :length, :integer
|
|
|
|
add :referrer, :string
|
|
add :referrer_source, :string
|
|
add :country_code, :string
|
|
add :screen_size, :string
|
|
add :operating_system, :string
|
|
add :browser, :string
|
|
|
|
timestamps(inserted_at: :timestamp, updated_at: false)
|
|
end
|
|
end
|
|
end
|