UPSERT results in a corrupt database
|User & Date:||drh 2018-07-11 13:37:14|
- Change icomment to:
The problem was that the affinity change from '1' to 1 on the PRIMARY KEY column was happening on the first constraint check in bytecode order, which is the UNIQUE constraint. But the PRIMARY KEY constraint was checked first, and hence was checked before the affinity change. The fix was to move the affinity change to before the branch that reorders the constraint checks for the UPSERT.
- Change login to "drh"
- Change mimetype to "text/x-fossil-wiki"
- Change resolution to "Fixed"
- Change status to "Fixed"