aboutsummaryrefslogtreecommitdiff
path: root/src/insert.c
diff options
context:
space:
mode:
authordrh <drh@noemail.net>2017-01-07 03:26:50 +0000
committerdrh <drh@noemail.net>2017-01-07 03:26:50 +0000
commitad1d9a870742dc5525ca1e884bbdb8cc66dd45e6 (patch)
treeb3c25b9c067d1f2c42ba89f280a92186a39bcceb /src/insert.c
parenta67b5cb6b32c61588eefdb76099545fcfcd3fcc0 (diff)
downloadsqlite-ad1d9a870742dc5525ca1e884bbdb8cc66dd45e6.tar.gz
sqlite-ad1d9a870742dc5525ca1e884bbdb8cc66dd45e6.zip
Avoid an unnecessary btree seek while deleting an index entry due to a conflict
on a REPLACE operation. FossilOrigin-Name: f0495c5133d0dc04d63521136d6b9ca440792cdf
Diffstat (limited to 'src/insert.c')
-rw-r--r--src/insert.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/insert.c b/src/insert.c
index e261c1994..e55ea2d9f 100644
--- a/src/insert.c
+++ b/src/insert.c
@@ -1651,7 +1651,7 @@ void sqlite3GenerateConstraintChecks(
}
sqlite3GenerateRowDelete(pParse, pTab, pTrigger, iDataCur, iIdxCur,
regR, nPkField, 0, OE_Replace,
- (pIdx==pPk ? ONEPASS_SINGLE : ONEPASS_OFF), -1);
+ (pIdx==pPk ? ONEPASS_SINGLE : ONEPASS_OFF), iThisCur);
seenReplace = 1;
break;
}