The match on ColumnFlags::UNSIGNED_FLAG would only work if UNSIGNED_FLAG was the only flag set.
If any other flag were set, such as the NOT_NULL flag, then it wouldn't match and the value would thus be coerced as an i32 instead. In the case of a u32, it would overflow, leading to upsert issues in the QE (and probably more issues).
Overview
fixes https://github.com/prisma/prisma/issues/15264 follow-up QE PR: https://github.com/prisma/prisma-engines/pull/3233
The match on
ColumnFlags::UNSIGNED_FLAG
would only work ifUNSIGNED_FLAG
was the only flag set. If any other flag were set, such as theNOT_NULL
flag, then it wouldn't match and the value would thus be coerced as ani32
instead. In the case of a u32, it would overflow, leading to upsert issues in the QE (and probably more issues).