-
Notifications
You must be signed in to change notification settings - Fork 27
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f5de79b
commit acd4c88
Showing
5 changed files
with
47 additions
and
13 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
28 changes: 28 additions & 0 deletions
28
...ostgres_database/migration/versions/d68b8128c23b_add_cols_to_licensed_items_purchases_.py
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,28 @@ | ||
"""add cols to licensed_items_purchases table 2 | ||
Revision ID: d68b8128c23b | ||
Revises: 8fa15c4c3977 | ||
Create Date: 2024-12-10 10:24:28.071216+00:00 | ||
""" | ||
import sqlalchemy as sa | ||
from alembic import op | ||
from sqlalchemy.dialects import postgresql | ||
|
||
# revision identifiers, used by Alembic. | ||
revision = "d68b8128c23b" | ||
down_revision = "8fa15c4c3977" | ||
branch_labels = None | ||
depends_on = None | ||
|
||
|
||
def upgrade(): | ||
op.drop_column("resource_tracker_licensed_items_purchases", "licensed_item_id") | ||
op.add_column( | ||
"resource_tracker_licensed_items_purchases", | ||
sa.Column("licensed_item_id", postgresql.UUID(as_uuid=True), nullable=False), | ||
) | ||
|
||
|
||
def downgrade(): | ||
... |
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 |
---|---|---|
|
@@ -26,7 +26,7 @@ | |
), | ||
sa.Column( | ||
"licensed_item_id", | ||
sa.BigInteger, | ||
UUID(as_uuid=True), | ||
nullable=False, | ||
), | ||
sa.Column( | ||
|
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