1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-11 01:42:22 +03:00

Add first cut of sqlite3_declare_vtab(). Not at all well tested yet. (CVS 3213)

FossilOrigin-Name: bbeb93b5bb26ba83ee7b7ae439ca5ceebebac9a0
This commit is contained in:
danielk1977
2006-06-12 11:24:37 +00:00
parent 78efaba10e
commit 7e6ebfb246
9 changed files with 225 additions and 45 deletions

View File

@@ -15,7 +15,7 @@
** individual tokens and sends those tokens one-by-one over to the
** parser for analysis.
**
** $Id: tokenize.c,v 1.119 2006/06/11 23:41:56 drh Exp $
** $Id: tokenize.c,v 1.120 2006/06/12 11:24:37 danielk1977 Exp $
*/
#include "sqliteInt.h"
#include "os.h"
@@ -483,10 +483,19 @@ abort_parse:
pParse->nTableLock = 0;
}
#endif
#ifndef SQLITE_OMIT_VIRTUALTABLE
sqliteFree(pParse->zArg);
#endif
sqlite3DeleteTable(pParse->db, pParse->pNewTable);
if( !IN_DECLARE_VTAB ){
/* If the pParse->declareVtab flag is set, do not delete any table
** structure built up in pParse->pNewTable. The calling code (see vtab.c)
** will take responsibility for freeing the Table structure.
*/
sqlite3DeleteTable(pParse->db, pParse->pNewTable);
}
sqlite3DeleteTrigger(pParse->pNewTrigger);
sqliteFree(pParse->apVarExpr);
if( nErr>0 && (pParse->rc==SQLITE_OK || pParse->rc==SQLITE_DONE) ){