Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

186
Vistas
Knex - Already up to date

I am struggling with a problem connected with the migrations in knex on the production environment (heroku). I have made some changes and created 8 new migrations to update the model. After creating new migrations I have reached 47 migration files. After uploading the changes to the Heroku I executed as usual knex migrate:latest and there was no effect. I have received the message Already up to date.

I have decided to take a look at the knex_migrations table to see if maybe something is wrong there. The result that I can see that the new migrations were not written into that database (please see the picture for reference.

enter image description here

When we take a look at the migrations it looks like this:

enter image description here

Clearly we can see that knex was able to run "20200216191040_receiver_company.js" as last one.

When I take a look at the knex_migrations_lock table the only entry that is existing over there looks like this:

enter image description here

Does anyone know how to force knex to run the migrations? The version of knex that I use it 0.16.3.

EDIT:

I want to add that on the local machine I have no problems with running the migrations. Additionally, I have checked if the migration files are present on the server and after pulling the current state our of the Heroku I can see all of the migration files that were not executed.

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

If the change of the migration is not implemented in the database, you can try to manually remove the record of the migration from the knex_migrations or you migrations table, and try to re-apply the knex migrate:latest command.

but before you try this way, make sure to keep a backup, or run it on your local machine or development server first.

over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda