is there any reason to not delete a record from th...
# orm-help
z
is there any reason to not delete a record from the
_prisma_migrations
table that has an
applied_steps_count=0
? I made a stupid mistake which is causing a rolled back migration to have have the same migration name as an applied migration (but different check sums)
👀 1
n
Hi @Zac Wellmer 👋 Apologies for delay in getting back to you. Is the migration record which you are trying to delete successfully applied? Assuming that the migration is successfully applied deleting the row would make
migrate deploy
apply the migration again next time it runs. It does not matter if there are migrations after this one, if it hasn’t been applied (or the record has been deleted, same thing), it will be applied. If the migration was edited, that will lead to a different outcome, and if it wasn’t, then you will get another row for it in _prisma___migrations. If the migration is gone from your migrations history, there is no harm in just keeping the row. My recommendation would be not to do it, your migrations table is a record of what happened, why change history? You can always write and apply a new migration.