Fixed collections on the ENUM columns.
This commit is contained in:
parent
31d89a08bf
commit
d1173c6e0f
1 changed files with 28 additions and 0 deletions
|
@ -0,0 +1,28 @@
|
|||
<?php
|
||||
use Index\Db\DbConnection;
|
||||
use Index\Db\Migration\DbMigration;
|
||||
|
||||
final class FixedCollationsOnNewlyAddedColumns_20250208_212359 implements DbMigration {
|
||||
public function migrate(DbConnection $conn): void {
|
||||
$conn->execute(<<<SQL
|
||||
ALTER TABLE msz_forum_posts
|
||||
CHANGE COLUMN post_text_format post_text_format ENUM('','bb','md') NOT NULL DEFAULT '' COLLATE 'ascii_general_ci' AFTER post_text;
|
||||
SQL);
|
||||
|
||||
$conn->execute(<<<SQL
|
||||
ALTER TABLE msz_messages
|
||||
CHANGE COLUMN msg_body_format msg_body_format ENUM('','bb','md') NOT NULL DEFAULT '' COLLATE 'ascii_general_ci' AFTER msg_body;
|
||||
SQL);
|
||||
|
||||
$conn->execute(<<<SQL
|
||||
ALTER TABLE msz_profile_backgrounds
|
||||
CHANGE COLUMN bg_attach bg_attach ENUM('cover','stretch','tile','contain') NOT NULL COLLATE 'ascii_general_ci' AFTER user_id;
|
||||
SQL);
|
||||
|
||||
$conn->execute(<<<SQL
|
||||
ALTER TABLE msz_users
|
||||
CHANGE COLUMN user_about_content_format user_about_content_format ENUM('','bb','md') NOT NULL DEFAULT '' COLLATE 'ascii_general_ci' AFTER user_about_content,
|
||||
CHANGE COLUMN user_signature_content_format user_signature_content_format ENUM('','bb','md') NOT NULL DEFAULT '' COLLATE 'ascii_general_ci' AFTER user_signature_content;
|
||||
SQL);
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue