2022-08-26 09:07:59 -07:00
|
|
|
import { MigrationInterface, QueryRunner } from 'typeorm';
|
|
|
|
|
|
|
|
|
|
export class ChangeExifFileSizeInByteToBigInt1661528919411 implements MigrationInterface {
|
|
|
|
|
name = 'ChangeExifFileSizeInByteToBigInt1661528919411';
|
|
|
|
|
|
|
|
|
|
public async up(queryRunner: QueryRunner): Promise<void> {
|
|
|
|
|
await queryRunner.query(`
|
|
|
|
|
ALTER TABLE exif
|
|
|
|
|
ALTER COLUMN "fileSizeInByte" type bigint using "fileSizeInByte"::bigint;
|
|
|
|
|
`);
|
|
|
|
|
}
|
|
|
|
|
|
2022-08-26 09:13:11 -07:00
|
|
|
public async down(queryRunner: QueryRunner): Promise<void> {
|
|
|
|
|
await queryRunner.query(`
|
|
|
|
|
ALTER TABLE exif
|
|
|
|
|
ALTER COLUMN "fileSizeInByte" type integer using "fileSizeInByte"::integer;
|
|
|
|
|
`);
|
|
|
|
|
}
|
2022-08-26 09:07:59 -07:00
|
|
|
}
|