]> git.ipfire.org Git - thirdparty/sqlite.git/commitdiff
In the command-line shell, output the elements of the schema in the order
authordrh <drh@noemail.net>
Mon, 6 May 2013 21:01:06 +0000 (21:01 +0000)
committerdrh <drh@noemail.net>
Mon, 6 May 2013 21:01:06 +0000 (21:01 +0000)
that they appear in the sqlite_master table.  This is necessary in some
cases to make the schema parsable.

FossilOrigin-Name: e5b3cd747bb0b484e38b8611a81925e2cc144435

manifest
manifest.uuid
src/shell.c

index 4ec94916cd60bd0dc10c102a42ee232711f761b9..394b3344deb0552fa010d90c5e243cba407f56e0 100644 (file)
--- a/manifest
+++ b/manifest
@@ -1,5 +1,5 @@
-C In\sthe\scommand-line\sshell,\smake\ssure\sthe\soutput\sof\sdot-commands\sgoes\sto\nthe\ssame\sredirected\soutput\sstream\sas\sthe\sresult\sof\squeries.\nTicket\s[2f96536e7ff7dba]
-D 2013-05-06T20:28:54.574
+C In\sthe\scommand-line\sshell,\soutput\sthe\selements\sof\sthe\sschema\sin\sthe\sorder\nthat\sthey\sappear\sin\sthe\ssqlite_master\stable.\s\sThis\sis\snecessary\sin\ssome\ncases\sto\smake\sthe\sschema\sparsable.
+D 2013-05-06T21:01:06.414
 F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f
 F Makefile.in ce81671efd6223d19d4c8c6b88ac2c4134427111
 F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23
@@ -191,7 +191,7 @@ F src/random.c cd4a67b3953b88019f8cd4ccd81394a8ddfaba50
 F src/resolve.c 83cc2d942ee216bc56956c6e6fadb691c1727fa1
 F src/rowset.c 64655f1a627c9c212d9ab497899e7424a34222e0
 F src/select.c 6bfbe11e2fef81c5e18d30513ab6c69f171667eb
-F src/shell.c 115bc2fa3ce4e89f5cea49ace173c4c9e68cfcf6
+F src/shell.c 2109d54f67c815a100abd7dc6a6e25eddb3b97eb
 F src/sqlite.h.in 5a5a22a9b192d81a9e5dee00274e3a0484c4afb1
 F src/sqlite3.rc fea433eb0a59f4c9393c8e6d76a6e2596b1fe0c0
 F src/sqlite3ext.h d936f797812c28b81b26ed18345baf8db28a21a5
@@ -1061,7 +1061,7 @@ F tool/vdbe-compress.tcl f12c884766bd14277f4fcedcae07078011717381
 F tool/warnings-clang.sh f6aa929dc20ef1f856af04a730772f59283631d4
 F tool/warnings.sh fbc018d67fd7395f440c28f33ef0f94420226381
 F tool/win/sqlite.vsix 97894c2790eda7b5bce3cc79cb2a8ec2fde9b3ac
-P d8dc2c5fb554eb5898ddc8d703c6a360af7fe023
-R 51c5817bdcc09862ecf820138ddcd721
+P b72d365920dbe45e61d8b1cff708a8858c2b3e33
+R e0d7d129e376f94da4504f4153569f21
 U drh
-Z 6618db8b151a5d589fef00beca7c472a
+Z e1d10da5e5ea459f8bce59c30cc68749
index c315d93ad3087d75fd0f4e0d63669bdbdc1c1f00..1562d7bd877cecc1e85980d1b80d5a81118a0f4e 100644 (file)
@@ -1 +1 @@
-b72d365920dbe45e61d8b1cff708a8858c2b3e33
\ No newline at end of file
+e5b3cd747bb0b484e38b8611a81925e2cc144435
\ No newline at end of file
index e6dd496bd1bc28aad30a9af6c0fa9306ca7e775f..1be2871fed9a1fdf1df7198e11253600ecba76cc 100644 (file)
@@ -2278,8 +2278,7 @@ static int do_meta_command(char *zLine, struct callback_data *p){
           "   SELECT sql, type, tbl_name, name, rowid FROM sqlite_temp_master) "
           "WHERE lower(tbl_name) LIKE shellstatic()"
           "  AND type!='meta' AND sql NOTNULL "
-          "ORDER BY substr(type,2,1), "
-                  " CASE type WHEN 'view' THEN rowid ELSE name END",
+          "ORDER BY rowid",
           callback, &data, &zErrMsg);
         zShellStatic = 0;
       }
@@ -2290,8 +2289,7 @@ static int do_meta_command(char *zLine, struct callback_data *p){
          "     FROM sqlite_master UNION ALL"
          "   SELECT sql, type, tbl_name, name, rowid FROM sqlite_temp_master) "
          "WHERE type!='meta' AND sql NOTNULL AND name NOT LIKE 'sqlite_%'"
-         "ORDER BY substr(type,2,1),"
-                  " CASE type WHEN 'view' THEN rowid ELSE name END",
+         "ORDER BY rowid",
          callback, &data, &zErrMsg
       );
     }