Skip to content

Commit

Permalink
Merge pull request #19 from kufu/add-revision-index
Browse files Browse the repository at this point in the history
実行に60〜90秒を要しているクエリのチューニング
  • Loading branch information
yamashush committed Sep 1, 2023
2 parents f20c849 + cdaa273 commit da7b602
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions lib/migrations/20230831234802-revision-add-index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
'use strict';

module.exports = {
up: (queryInterface, Sequelize) => {
return queryInterface.addIndex('Revisions', ['noteId'], {})
},

down: (queryInterface, Sequelize) => {
return queryInterface.removeIndex('Revisions', 'noteId')
}
};

0 comments on commit da7b602

Please sign in to comment.