connection->getDatabasePlatform()); $table = $schema->getTable('short_urls'); $column = $table->getColumn('short_code'); match ($platformClass) { MySQLPlatform::class => $column->setPlatformOption('collation', 'utf8_bin'), SqlitePlatform::class => $column->setPlatformOption('collate', 'BINARY'), default => null, }; } public function down(Schema $schema): void { // Nothing to roll back } public function isTransactional(): bool { return ! ($this->connection->getDatabasePlatform() instanceof MySQLPlatform); } }