1
0
mirror of https://github.com/quay/quay.git synced 2026-01-26 06:21:37 +03:00

migration: alter id column type for table manifestblob (#3885)

* migration: alter id column type for table manifestblob

* adding raw queries
This commit is contained in:
Sunandadadi
2025-05-13 10:21:20 -04:00
committed by GitHub
parent 7ca6f7c6ed
commit d3bcbe0610

View File

@@ -0,0 +1,37 @@
"""alter manifestblob id
Revision ID: e8ed3fb547da
Revises: 3634f2df3c5b
Create Date: 2025-05-13 09:45:39.152681
"""
# revision identifiers, used by Alembic.
revision = "e8ed3fb547da"
down_revision = "3634f2df3c5b"
import sqlalchemy as sa
def upgrade(op, tables, tester):
bind = op.get_bind()
if bind.engine.name == "postgresql":
op.execute(
"""
ALTER TABLE manifestblob ALTER COLUMN id TYPE BIGINT;
"""
)
op.execute(
"""
ALTER SEQUENCE manifestblob_id_seq AS BIGINT;
"""
)
op.execute(
"""
ALTER SEQUENCE manifestblob_id_seq MAXVALUE 9223372036854775807;
"""
)
def downgrade(op, tables, tester):
pass