<filename>discovery-provider/alembic/versions/7857f02c8438_ix_plays_created_at.py<gh_stars>100-1000
"""ix_plays_created_at

Revision ID: <KEY>
Revises: 92571f94<PASSWORD>a
Create Date: 2021-10-13 17:39:36.424969

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = '<KEY>'
down_revision = '92571f94989a'
branch_labels = None
depends_on = None


def upgrade():
    connection = op.get_bind()

    connection.execute(
        """
        begin;
            CREATE INDEX IF NOT EXISTS "ix_plays_created_at" ON "plays" ("created_at");
        commit;
    """
    )


def downgrade():
    connection = op.get_bind()

    connection.execute(
        """
        begin;
            DROP INDEX ix_plays_created_at;
        commit;
    """
    )

<filename>discovery-provider/alembic/versions/7857f02c8438_ix_plays_created_at.py<gh_stars>100-1000
"""ix_plays_created_at

Revision ID: <KEY>
Revises: 92571f94<PASSWORD>a
Create Date: 2021-10-13 17:39:36.424969

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = '<KEY>'
down_revision = '92571f94989a'
branch_labels = None
depends_on = None


def upgrade():
    connection = op.get_bind()

    connection.execute(
        """
        begin;
            CREATE INDEX IF NOT EXISTS "ix_plays_created_at" ON "plays" ("created_at");
        commit;
    """
    )


def downgrade():
    connection = op.get_bind()

    connection.execute(
        """
        begin;
            DROP INDEX ix_plays_created_at;
        commit;
    """
    )

ix_plays_created_at  Revision ID: <KEY> Revises: 92571f94<PASSWORD>a Create Date: 2021-10-13 17:39:36.424969 # revision identifiers, used by Alembic. begin;             CREATE INDEX IF NOT EXISTS "ix_plays_created_at" ON "plays" ("created_at");         commit; begin;             DROP INDEX ix_plays_created_at;         commit;