PrismaP
Prisma2y ago
3 replies
Niels

Prisma keeps generating same migrations

Hmm, I am having some weird issue with my "Invoice" model.. whenever I generate a migration, it keeps adding these lines to the migrations, over and over... What could be the cause of this?

-- AlterTable
ALTER TABLE `Invoice` MODIFY `amountTotal` DOUBLE NOT NULL DEFAULT (round(`amountSubtotal` + `amountTax`, 2)),
    MODIFY `displayId` VARCHAR(191) NOT NULL DEFAULT id;


2 migrations, just created...
image.png
image.png
Solution
Solution: After using prisma db pull I saw that the database returned these formulas without spaces, so I had to change those values in the prisma schema and now it seems to be okay 🙂
Was this page helpful?