Skip to content

Migrations generated with function as DEFAULT will create multiple alter

Notifications You must be signed in to change notification settings

ffd114/migration-with-function

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Issue type:

  • question
  • bug report
  • feature request
  • documentation issue

Database system/driver:

  • cordova
  • mongodb
  • mssql
  • mysql / mariadb
  • oracle
  • postgres
  • sqlite
  • sqljs
  • websql

TypeORM version:

  • latest
  • @next
  • 0.x.x (or put your version here)

Steps to reproduce or a small repository showing the problem:

  1. Create entity, e.g: User with column email
  2. Generate and run migration typeorm migrations:generate -n Init && typeorm migrations:run
  3. Add new column createdAt with default set to () => 'NOW()'
  4. Generate and run migration typeorm migrations:generate -n AlterCreated && typeorm migrations:run
  5. Add new column name
  6. If we generate migration again typeorm migrations:generate -n Test, the queries that generated because the changes on step 3 will show up again

About

Migrations generated with function as DEFAULT will create multiple alter

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published