Skip to content

Commit

Permalink
db: fix database
Browse files Browse the repository at this point in the history
  • Loading branch information
mickamy committed Jan 3, 2024
1 parent ee0dbd3 commit fc5eba5
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions docker/app/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ sudo mysql -u root -pishocon -e "CREATE USER IF NOT EXISTS ishocon IDENTIFIED BY
sudo mysql -u root -pishocon -e 'GRANT ALL ON *.* TO ishocon;' && \
cd ~/data && tar -jxvf ishocon2.dump.tar.bz2 && sudo mysql -u root -pishocon ishocon2 < ~/data/ishocon2.dump
sudo mysql -u root -pishocon -e '
use ishocon2;
ALTER TABLE votes ADD COLUMN count int(4) NOT NULL;
ALTER TABLE votes ADD INDEX (candidate_id, count DESC);
ALTER TABLE votes DROP COLUMN keyword;
Expand Down

0 comments on commit fc5eba5

Please sign in to comment.