Skip to content

Commit

Permalink
chore: V1.19.0 のマイグレーションで playerdata の uuid カラムに依存させない
Browse files Browse the repository at this point in the history
  • Loading branch information
rito528 committed Feb 5, 2025
1 parent f4587e6 commit ddc8620
Showing 1 changed file with 1 addition and 8 deletions.
Original file line number Diff line number Diff line change
@@ -1,13 +1,6 @@
USE seichiassist;

CREATE TABLE IF NOT EXISTS player_break_suppression_preference(
-- `SET ...` がないと Foreign key constraint is incorrectly formed が発生し
-- `SHOW ENGINE INNODB STATUS` を実行すると
-- Error in foreign key constraint of table seichiassist.player_break_suppression_preference:
-- Create table seichiassist.player_break_suppression_preference with foreign key fk_player_break_suppression_preference_uuid constraint failed.
-- Field type or character set for column 'uuid' does not match referenced column 'uuid'
-- となり、 playerdata.uuid のデータ型は CHAR(36) 文字コードを指定する
uuid CHAR(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL PRIMARY KEY,
uuid CHAR(36) NOT NULL PRIMARY KEY,
do_break_suppression_due_to_mana BOOL NOT NULL DEFAULT FALSE,
FOREIGN KEY fk_player_break_suppression_preference_uuid(uuid) REFERENCES playerdata(uuid)
);

0 comments on commit ddc8620

Please sign in to comment.