@marcelklehr the index will be missing for new installations until the admin notices the missing index warning and applies it manually.
Therefore it's recommended to edit the original migration adding the table to already apply the index. That would be lib/Migration/Version004004000Date20250523135634.php in this case. Leave a comment to make it obvious that the migration was changed, like you can see here: https://github.com/nextcloud/server/blob/2f2049cbeb7ee51204ebe6610a29663281a62d49/core/Migrations/Version13000Date20170718121200.php#L735-L738
Originally posted by @ChristophWurst in #166 (comment)