Skip to content

Commit c29b93f

Browse files
authored
add migration (#4932)
1 parent 14fa39e commit c29b93f

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
defmodule Plausible.IngestRepo.Migrations.AddPageleaveVisitorsToImportedPages do
2+
use Ecto.Migration
3+
4+
@on_cluster Plausible.MigrationUtils.on_cluster_statement("imported_pages")
5+
6+
def up do
7+
execute """
8+
ALTER TABLE imported_pages
9+
#{@on_cluster}
10+
ADD COLUMN pageleave_visitors UInt64
11+
"""
12+
end
13+
14+
def down do
15+
execute """
16+
ALTER TABLE imported_pages
17+
#{@on_cluster}
18+
DROP COLUMN pageleave_visitors
19+
"""
20+
end
21+
end

0 commit comments

Comments
 (0)