aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authordrh <drh@noemail.net>2007-02-24 15:18:49 +0000
committerdrh <drh@noemail.net>2007-02-24 15:18:49 +0000
commitfb658dedce94cc9df06cda5127f6c616a01d4403 (patch)
tree638559eff7b50719073667f4191b02022b171d22 /src
parentdd73521bc26ccd24bc8652f672c74c2fcdc6f0f4 (diff)
downloadsqlite-fb658dedce94cc9df06cda5127f6c616a01d4403.tar.gz
sqlite-fb658dedce94cc9df06cda5127f6c616a01d4403.zip
Additional test cases added. Improvements to the INSERT transfer
optimization. (CVS 3662) FossilOrigin-Name: 2bf5475bde763f73f7f4dd9cac7d13a631a7d2aa
Diffstat (limited to 'src')
-rw-r--r--src/insert.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/insert.c b/src/insert.c
index 84853d980..8b0f76bea 100644
--- a/src/insert.c
+++ b/src/insert.c
@@ -12,7 +12,7 @@
** This file contains C code routines that are called by the parser
** to handle INSERT statements in SQLite.
**
-** $Id: insert.c,v 1.175 2007/02/24 13:53:05 drh Exp $
+** $Id: insert.c,v 1.176 2007/02/24 15:18:50 drh Exp $
*/
#include "sqliteInt.h"
@@ -1462,7 +1462,7 @@ static int xferOptimization(
return 0; /* pDestIdx has no corresponding index in pSrc */
}
}
- if( !sqlite3ExprCompare(pSrc->pCheck, pDest->pCheck) ){
+ if( pDest->pCheck && !sqlite3ExprCompare(pSrc->pCheck, pDest->pCheck) ){
return 0; /* Tables have different CHECK constraints. Ticket #2252 */
}