Prisma P2025 / P2018: why are required records missing?
Summary As of October 2026, inspect the failing selector and relation before changing Prisma writes: P2025 means required records are missing, while P2018 names connected records. Use upsert() only when creating an absent record is intended; it is not a universal repair (checked 2026-10-28).