aboutsummaryrefslogtreecommitdiff
path: root/src/where.c
diff options
context:
space:
mode:
authordan <dan@noemail.net>2014-01-16 18:34:33 +0000
committerdan <dan@noemail.net>2014-01-16 18:34:33 +0000
commiteae73fbfb90594c3a56f16a55f69270f18d61bab (patch)
treef73e66dde21cd9902d4ac41b0bda638c88fb409c /src/where.c
parent8290c2ad5ad48cffe78f51a25109398ad2b49c41 (diff)
downloadsqlite-eae73fbfb90594c3a56f16a55f69270f18d61bab.tar.gz
sqlite-eae73fbfb90594c3a56f16a55f69270f18d61bab.zip
Allow only a single recursive reference in a recursive CTE. Also require that this reference is not part of a sub-query.
FossilOrigin-Name: a296b73360d34c9364eceb2cc09a9a92adc4abb8
Diffstat (limited to 'src/where.c')
-rw-r--r--src/where.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/where.c b/src/where.c
index f1cf29b2e..52bf46a74 100644
--- a/src/where.c
+++ b/src/where.c
@@ -5654,13 +5654,7 @@ WhereInfo *sqlite3WhereBegin(
iDb = sqlite3SchemaToIndex(db, pTab->pSchema);
pLoop = pLevel->pWLoop;
if( (pTab->tabFlags & TF_Ephemeral)!=0 || pTab->pSelect ){
-#ifndef SQLITE_OMIT_CTE
- if( pTab->tabFlags & TF_Recursive ){
- int iCur = pTabItem->iCursor;
- sqlite3VdbeAddOp2(v, OP_OpenEphreader, iCur, pTab->tnum);
- }
-#endif
- /* Otherwise do nothing */
+ /* Do nothing */
}else
#ifndef SQLITE_OMIT_VIRTUALTABLE
if( (pLoop->wsFlags & WHERE_VIRTUALTABLE)!=0 ){