forked from plausible/analytics
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #21 from Recruitee/change-campaign-id-and-product-…
…id-field-types Change campaign_id and product_id field types
- Loading branch information
Showing
5 changed files
with
45 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
priv/clickhouse_repo/migrations/20221130162330_remove_campaign_id.exs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
defmodule Plausible.ClickhouseRepo.Migrations.RemoveCampaignId do | ||
use Ecto.Migration | ||
|
||
def change do | ||
alter table(:events) do | ||
remove :campaign_id | ||
end | ||
|
||
alter table(:sessions) do | ||
remove :campaign_id | ||
end | ||
end | ||
end |
13 changes: 13 additions & 0 deletions
13
priv/clickhouse_repo/migrations/20221130162430_remove_product_id.exs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
defmodule Plausible.ClickhouseRepo.Migrations.RemoveProductId do | ||
use Ecto.Migration | ||
|
||
def change do | ||
alter table(:events) do | ||
remove :product_id | ||
end | ||
|
||
alter table(:sessions) do | ||
remove :product_id | ||
end | ||
end | ||
end |
15 changes: 15 additions & 0 deletions
15
priv/clickhouse_repo/migrations/20221130174130_recreate_campaign_id_and_product_id.exs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
defmodule Plausible.ClickhouseRepo.Migrations.RecreateCampaignIdAndProductId do | ||
use Ecto.Migration | ||
|
||
def change do | ||
alter table(:events) do | ||
add(:campaign_id, :string) | ||
add(:product_id, :string) | ||
end | ||
|
||
alter table(:sessions) do | ||
add(:campaign_id, :string) | ||
add(:product_id, :string) | ||
end | ||
end | ||
end |