Add a parallel package for query results.

This commit is contained in:
Patrick Jentsch
2020-07-13 15:33:00 +02:00
parent 2b3d08b277
commit 6760061d53
16 changed files with 852 additions and 35 deletions

View File

@ -0,0 +1,30 @@
"""empty message
Revision ID: 33ec4d09b4ca
Revises: 4cf5e5606a83
Create Date: 2020-07-13 09:07:19.297185
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '33ec4d09b4ca'
down_revision = '4cf5e5606a83'
branch_labels = None
depends_on = None
def upgrade():
# ### commands auto generated by Alembic - please adjust! ###
op.add_column('query_results', sa.Column('description', sa.String(length=255), nullable=True))
op.add_column('query_results', sa.Column('title', sa.String(length=32), nullable=True))
# ### end Alembic commands ###
def downgrade():
# ### commands auto generated by Alembic - please adjust! ###
op.drop_column('query_results', 'title')
op.drop_column('query_results', 'description')
# ### end Alembic commands ###

View File

@ -0,0 +1,35 @@
"""empty message
Revision ID: 4cf5e5606a83
Revises: e256f5cac75d
Create Date: 2020-07-13 08:30:57.369850
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '4cf5e5606a83'
down_revision = 'e256f5cac75d'
branch_labels = None
depends_on = None
def upgrade():
# ### commands auto generated by Alembic - please adjust! ###
op.create_table('query_results',
sa.Column('id', sa.Integer(), nullable=False),
sa.Column('user_id', sa.Integer(), nullable=True),
sa.Column('filename', sa.String(length=255), nullable=True),
sa.Column('query_metadata', sa.JSON(), nullable=True),
sa.ForeignKeyConstraint(['user_id'], ['users.id'], ),
sa.PrimaryKeyConstraint('id')
)
# ### end Alembic commands ###
def downgrade():
# ### commands auto generated by Alembic - please adjust! ###
op.drop_table('query_results')
# ### end Alembic commands ###