12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576 |
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
- <html><head>
- <title>SQLite Query Language: EXPLAIN</title>
- <style type="text/css">
- body {
- margin: auto;
- font-family: Verdana, sans-serif;
- padding: 8px 1%;
- }
- a { color: #45735f }
- a:visited { color: #734559 }
- .logo { position:absolute; margin:3px; }
- .tagline {
- float:right;
- text-align:right;
- font-style:italic;
- width:240px;
- margin:12px;
- margin-top:58px;
- }
- .toolbar {
- font-variant: small-caps;
- text-align: center;
- line-height: 1.6em;
- margin: 0;
- padding:1px 8px;
- }
- .toolbar a { color: white; text-decoration: none; padding: 6px 12px; }
- .toolbar a:visited { color: white; }
- .toolbar a:hover { color: #80a796; background: white; }
- .content { margin: 5%; }
- .content dt { font-weight:bold; }
- .content dd { margin-bottom: 25px; margin-left:20%; }
- .content ul { padding:0px; padding-left: 15px; margin:0px; }
- /* rounded corners */
- .se { background: url(images/se.png) 100% 100% no-repeat #80a796}
- .sw { background: url(images/sw.png) 0% 100% no-repeat }
- .ne { background: url(images/ne.png) 100% 0% no-repeat }
- .nw { background: url(images/nw.png) 0% 0% no-repeat }
- </style>
- <meta http-equiv="content-type" content="text/html; charset=UTF-8">
-
- </head>
- <body>
- <div><!-- container div to satisfy validator -->
- <a href="lang.html">
- <h2 align="center">SQL As Understood By SQLite</h2></a><h1>EXPLAIN</h1><h4><a href="syntaxdiagrams.html#sql-stmt">sql-stmt:</a></h4><blockquote> <img alt="syntax diagram sql-stmt" src="images/syntax/sql-stmt.gif"></img> </blockquote>
- <p>An SQL statement can be preceded by the keyword "EXPLAIN" or
- by the phrase "EXPLAIN QUERY PLAN". Either modification causes the
- SQL statement to behave as a query and to return information about
- how the SQL statement would have operated if the EXPLAIN keyword or
- phrase had been omitted.</p>
- <p>When the EXPLAIN keyword appears by itself it causes the statement
- to behave as a query that returns the sequence of
- virtual machine instructions it would have
- used to execute the command had the EXPLAIN keyword not been present.
- When the EXPLAIN QUERY PLAN phrase appears, the statement returns
- high-level information about what indices would have been used.</p>
- <p>The output from EXPLAIN and EXPLAIN QUERY PLAN is intended for
- interactive analysis and troubleshooting only. The details of the
- output format are subject to change from one release of SQLite to the next.
- Applications should not use EXPLAIN or EXPLAIN QUERY PLAN since
- their behavior is undocumented, unspecified, and variable.</p>
|