This commit is contained in:
parent
caf0e44f3e
commit
2768e4434a
@ -16,13 +16,6 @@ defmodule LoLAnalytics.Repo.Migrations.AnalyticsTables do
|
|||||||
|
|
||||||
create index("dim_item", [:item_id], unique: true)
|
create index("dim_item", [:item_id], unique: true)
|
||||||
|
|
||||||
create table("dim_match") do
|
|
||||||
add :match_id, :string, primary_key: true, null: false
|
|
||||||
timestamps()
|
|
||||||
end
|
|
||||||
|
|
||||||
create index("dim_match", [:match_id], unique: true)
|
|
||||||
|
|
||||||
create table("dim_patch") do
|
create table("dim_patch") do
|
||||||
add :patch_number, :string, primary_key: true, null: false
|
add :patch_number, :string, primary_key: true, null: false
|
||||||
timestamps()
|
timestamps()
|
||||||
@ -30,6 +23,15 @@ defmodule LoLAnalytics.Repo.Migrations.AnalyticsTables do
|
|||||||
|
|
||||||
create index("dim_patch", [:patch_number], unique: true)
|
create index("dim_patch", [:patch_number], unique: true)
|
||||||
|
|
||||||
|
create table("dim_match") do
|
||||||
|
add :patch_number, references("dim_patch", column: :patch_number, type: :string)
|
||||||
|
add :match_id, :string, primary_key: true, null: false
|
||||||
|
timestamps()
|
||||||
|
end
|
||||||
|
|
||||||
|
create index("dim_match", [:patch_number])
|
||||||
|
create index("dim_match", [:match_id], unique: true)
|
||||||
|
|
||||||
create table("dim_player") do
|
create table("dim_player") do
|
||||||
add :puuid, :string, primary_key: true, null: false
|
add :puuid, :string, primary_key: true, null: false
|
||||||
timestamps()
|
timestamps()
|
||||||
|
@ -0,0 +1,15 @@
|
|||||||
|
defmodule LoLAnalytics.Repo.Migrations.DimMatchFactProcessingStatus do
|
||||||
|
use Ecto.Migration
|
||||||
|
|
||||||
|
def change do
|
||||||
|
alter table("dim_match") do
|
||||||
|
add :fact_champion_played_game_status, :integer
|
||||||
|
add :fact_champion_picked_item_status, :integer
|
||||||
|
add :fact_champion_picked_summoner_spell_status, :integer
|
||||||
|
end
|
||||||
|
|
||||||
|
create index("dim_match", [:fact_champion_played_game_status])
|
||||||
|
create index("dim_match", [:fact_champion_picked_item_status])
|
||||||
|
create index("dim_match", [:fact_champion_picked_summoner_spell_status])
|
||||||
|
end
|
||||||
|
end
|
Loading…
x
Reference in New Issue
Block a user