aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/build.c3
-rw-r--r--src/shell.c.in4
2 files changed, 2 insertions, 5 deletions
diff --git a/src/build.c b/src/build.c
index 106b995d3..a3d1abf04 100644
--- a/src/build.c
+++ b/src/build.c
@@ -2816,7 +2816,8 @@ void sqlite3DropTable(Parse *pParse, SrcList *pName, int isView, int noErr){
}
#endif
if( sqlite3StrNICmp(pTab->zName, "sqlite_", 7)==0
- && sqlite3StrNICmp(pTab->zName, "sqlite_stat", 11)!=0 ){
+ && sqlite3StrNICmp(pTab->zName+7, "stat", 4)!=0
+ && sqlite3StrNICmp(pTab->zName+7, "parameters", 10)!=0 ){
sqlite3ErrorMsg(pParse, "table %s may not be dropped", pTab->zName);
goto exit_drop_table;
}
diff --git a/src/shell.c.in b/src/shell.c.in
index bde360b0e..549216e32 100644
--- a/src/shell.c.in
+++ b/src/shell.c.in
@@ -8148,12 +8148,8 @@ static int do_meta_command(char *zLine, ShellState *p){
** Clear all bind parameters by dropping the TEMP table that holds them.
*/
if( nArg==2 && strcmp(azArg[1],"clear")==0 ){
- int wrSchema = 0;
- sqlite3_db_config(p->db, SQLITE_DBCONFIG_WRITABLE_SCHEMA, -1, &wrSchema);
- sqlite3_db_config(p->db, SQLITE_DBCONFIG_WRITABLE_SCHEMA, 1, 0);
sqlite3_exec(p->db, "DROP TABLE IF EXISTS temp.sqlite_parameters;",
0, 0, 0);
- sqlite3_db_config(p->db, SQLITE_DBCONFIG_WRITABLE_SCHEMA, wrSchema, 0);
}else
/* .parameter list