You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: webapp/migrations/Version20250309122806.php
+3-2Lines changed: 3 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -4,6 +4,7 @@
4
4
5
5
namespaceDoctrineMigrations;
6
6
7
+
useApp\Entity\RankCache;
7
8
useDoctrine\DBAL\Schema\Schema;
8
9
useDoctrine\Migrations\AbstractMigration;
9
10
@@ -21,8 +22,8 @@ public function up(Schema $schema): void
21
22
{
22
23
// this up() migration is auto-generated, please modify it to your needs
23
24
$this->addSql('ALTER TABLE rankcache ADD sort_key_public TEXT DEFAULT \'\' NOT NULL COMMENT \'Opaque sort key for public audience.\', ADD sort_key_restricted TEXT DEFAULT \'\' NOT NULL COMMENT \'Opaque sort key for restricted audience.\'');
24
-
$this->addSql('CREATE INDEX sortKeyPublic ON rankcache (sort_key_public)');
25
-
$this->addSql('CREATE INDEX sortKeyRestricted ON rankcache (sort_key_restricted)');
25
+
$this->addSql(sprintf('CREATE INDEX sortKeyPublic ON rankcache (sort_key_public(%s))', RankCache::SORT_KEY_INDEX_SIZE));
26
+
$this->addSql(sprintf('CREATE INDEX sortKeyRestricted ON rankcache (sort_key_restricted(%s))', RankCache::SORT_KEY_INDEX_SIZE));
// this up() migration is auto-generated, please modify it to your needs
23
+
$this->addSql('ALTER TABLE judging CHANGE max_runtime_for_verdict max_runtime_for_verdict NUMERIC(32, 9) UNSIGNED DEFAULT NULL COMMENT \'The maximum runtime for all runs that resulted in the verdict\'');
24
+
$this->addSql('ALTER TABLE problem CHANGE types types INT NOT NULL COMMENT \'Bitmask of problem types, default is pass-fail.\'');
25
+
}
26
+
27
+
publicfunctiondown(Schema$schema): void
28
+
{
29
+
// this down() migration is auto-generated, please modify it to your needs
30
+
$this->addSql('ALTER TABLE problem CHANGE types types INT NOT NULL COMMENT \'Bitset of problem types, default is pass-fail.\'');
31
+
$this->addSql('ALTER TABLE judging CHANGE max_runtime_for_verdict max_runtime_for_verdict NUMERIC(32, 9) UNSIGNED DEFAULT NULL COMMENT \'The maximum run time for all runs that resulted in the verdict\'');
0 commit comments