From: drh Date: Sat, 13 Apr 2002 23:42:24 +0000 (+0000) Subject: When doing a ".dump" command in the command-line shell, make sure VIEWs X-Git-Tag: version-3.6.10~5546 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=fc6cdfe9dcf18bfd3f7206e50e659c3b4a0d3f48;p=thirdparty%2Fsqlite.git When doing a ".dump" command in the command-line shell, make sure VIEWs are created after TABLEs. (CVS 529) FossilOrigin-Name: 7edd13468e24d79939f0fa1e58f3b686422ca826 --- diff --git a/manifest b/manifest index c95c93ed40..1b3a2afa8d 100644 --- a/manifest +++ b/manifest @@ -1,5 +1,5 @@ -C Version\s2.4.7\s(CVS\s528) -D 2002-04-12T13:12:25 +C When\sdoing\sa\s".dump"\scommand\sin\sthe\scommand-line\sshell,\smake\ssure\sVIEWs\nare\screated\safter\sTABLEs.\s(CVS\s529) +D 2002-04-13T23:42:24 F Makefile.in 50f1b3351df109b5774771350d8c1b8d3640130d F Makefile.template 89e373b2dad0321df00400fa968dc14b61a03296 F README a4c0ba11354ef6ba0776b400d057c59da47a4cc0 @@ -39,7 +39,7 @@ F src/parse.y 9a8a2311dd95101bb02b3991042e619eea49729a F src/printf.c 300a90554345751f26e1fc0c0333b90a66110a1d F src/random.c 19e8e00fe0df32a742f115773f57651be327cabe F src/select.c 92aef3f69e90dc065d680d88b1f075409e9249bb -F src/shell.c 994ca7c8c40c40a95011812013fbbf9828f5a0e7 +F src/shell.c 66bf0478c35343d9b795e435b54b45a4ab29f2ef F src/shell.tcl 27ecbd63dd88396ad16d81ab44f73e6c0ea9d20e F src/sqlite.h.in ffcacf73b5ed1a4939205d29a704a185758fa6a6 F src/sqliteInt.h e47ca9267a4c4a98e9f8d90c2df994a18f23d699 @@ -131,7 +131,7 @@ F www/speed.tcl da8afcc1d3ccc5696cfb388a68982bc3d9f7f00f F www/sqlite.tcl 8b5884354cb615049aed83039f8dfe1552a44279 F www/tclsqlite.tcl 1db15abeb446aad0caf0b95b8b9579720e4ea331 F www/vdbe.tcl 2013852c27a02a091d39a766bc87cff329f21218 -P cdab6dad323dd1e95ec8b7684a7c4b06c75905e0 -R 1c28bb516c3dd5de76adf35f517aa9d2 +P 977abbaebe5433c66516d0376a1c229e45b5ab1f +R 1d18e0543c9a9e3b6f1f1a88dc469706 U drh -Z d200ee117509d1e57c2f812ec0f48fa6 +Z c041d10ac3286386a2e3e11a69a41456 diff --git a/manifest.uuid b/manifest.uuid index 97098b4aa6..5f5f652d4c 100644 --- a/manifest.uuid +++ b/manifest.uuid @@ -1 +1 @@ -977abbaebe5433c66516d0376a1c229e45b5ab1f \ No newline at end of file +7edd13468e24d79939f0fa1e58f3b686422ca826 \ No newline at end of file diff --git a/src/shell.c b/src/shell.c index 3e953bdae5..720da68e3b 100644 --- a/src/shell.c +++ b/src/shell.c @@ -12,7 +12,7 @@ ** This file contains code to implement the "sqlite" command line ** utility for accessing SQLite databases. ** -** $Id: shell.c,v 1.49 2002/04/08 02:42:58 drh Exp $ +** $Id: shell.c,v 1.50 2002/04/13 23:42:24 drh Exp $ */ #include #include @@ -497,7 +497,7 @@ static void do_meta_command(char *zLine, sqlite *db, struct callback_data *p){ sqlite_exec(db, "SELECT name, type, sql FROM sqlite_master " "WHERE type!='meta' AND sql NOT NULL " - "ORDER BY tbl_name, type DESC, name", + "ORDER BY substr(type,2,1), name", dump_callback, p, &zErrMsg ); }else{ @@ -506,10 +506,9 @@ static void do_meta_command(char *zLine, sqlite *db, struct callback_data *p){ sqlite_exec_printf(db, "SELECT name, type, sql FROM sqlite_master " "WHERE tbl_name LIKE '%q' AND type!='meta' AND sql NOT NULL " - "ORDER BY type DESC, name", + "ORDER BY substr(type,2,1), name", dump_callback, p, &zErrMsg, azArg[i] ); - } } if( zErrMsg ){