"""add events data table

Revision ID: dd2c6c20cf7f
Revises: 4110d9271ed4
Create Date: 2021-03-10 16:36:08.386965

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = 'dd2c6c20cf7f'
down_revision = '4110d9271ed4'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('EventsData',
    sa.Column('id', sa.Integer(), nullable=False),
    sa.Column('name_player', sa.String(), nullable=False),
    sa.Column('sex_player', sa.String(), nullable=False),
    sa.Column('age_player', sa.String(), nullable=False),
    sa.Column('gun_player', sa.String(), nullable=False),
    sa.Column('section_player', sa.String(), nullable=False),
    sa.Column('result_player', sa.Integer(), nullable=True),
    sa.Column('id_event', sa.Integer(), nullable=False),
    sa.ForeignKeyConstraint(['id_event'], ['EVENTS.id'], ),
    sa.PrimaryKeyConstraint('id')
    )
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_table('EventsData')
    # ### end Alembic commands ###
