mirror of
https://github.com/n8n-io/n8n.git
synced 2025-01-23 18:41:48 -08:00
24 lines
616 B
TypeScript
24 lines
616 B
TypeScript
import type { MigrationContext, ReversibleMigration } from '@db/types';
|
|
|
|
export class CreateIndexStoppedAt1594902918301 implements ReversibleMigration {
|
|
async up({ queryRunner, tablePrefix }: MigrationContext) {
|
|
await queryRunner.query(
|
|
'CREATE INDEX `IDX_' +
|
|
tablePrefix +
|
|
'cefb067df2402f6aed0638a6c1` ON `' +
|
|
tablePrefix +
|
|
'execution_entity` (`stoppedAt`)',
|
|
);
|
|
}
|
|
|
|
async down({ queryRunner, tablePrefix }: MigrationContext) {
|
|
await queryRunner.query(
|
|
'DROP INDEX `IDX_' +
|
|
tablePrefix +
|
|
'cefb067df2402f6aed0638a6c1` ON `' +
|
|
tablePrefix +
|
|
'execution_entity`',
|
|
);
|
|
}
|
|
}
|