diff --git a/migrations/104-tournament-match-opponent-indexes.js b/migrations/104-tournament-match-opponent-indexes.js new file mode 100644 index 000000000..c15644c81 --- /dev/null +++ b/migrations/104-tournament-match-opponent-indexes.js @@ -0,0 +1,11 @@ +export function up(db) { + db.transaction(() => { + db.prepare( + /* sql */ `create index idx_tournament_match_opponent_one_id on "TournamentMatch"("opponentOne" ->> '$.id')`, + ).run(); + + db.prepare( + /* sql */ `create index idx_tournament_match_opponent_two_id on "TournamentMatch"("opponentTwo" ->> '$.id')`, + ).run(); + })(); +}