<html dir="LTR" xmlns="http://www.w3.org/1999/xhtml" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:MSHelp="http://msdn.microsoft.com/mshelp" xmlns:tool="http://www.microsoft.com/tooltip" xmlns:ndoc="urn:ndoc-preprocess">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252" />
<title>SQLite Query Syntax</title>
<link rel="stylesheet" type="text/css" href="ndoc.css"> </link>
<link rel="stylesheet" type="text/css" href="user.css"> </link>
<script type="text/javascript" src="ndoc.js"> </script>
</head>
<body style="display: none;">
<input type="hidden" id="userDataCache" class="userDataStyle" />
<input type="hidden" id="hiddenScrollOffset" />
<img id="dropDownImage" style="display:none; height:0; width:0;" src="drpdown.gif" />
<img id="dropDownHoverImage" style="display:none; height:0; width:0;" src="drpdown_orange.gif" />
<img id="collapseImage" style="display:none; height:0; width:0;" src="collapse.gif" />
<img id="expandImage" style="display:none; height:0; width:0;" src="exp.gif" />
<img id="collapseAllImage" style="display:none; height:0; width:0;" src="collall.gif" />
<img id="expandAllImage" style="display:none; height:0; width:0;" src="expall.gif" />
<img id="copyImage" style="display:none; height:0; width:0;" src="copycode.gif" />
<img id="copyHoverImage" style="display:none; height:0; width:0;" src="copycodeHighlight.gif" />
<div id="header">
<table width="100%" id="topTable">
<tr id="headerTableRow1">
<td align="left">
<span id="runningHeaderText">SQLite Query Syntax</span> </td>
</tr>
<tr id="headerTableRow2">
<td align="left">
<span id="nsrTitle">SQLite Language Reference Documentation</span>
</td>
</tr>
<tr id="headerTableRow3" style="display:none">
<td>
<a id="seeAlsoSectionLink" href="#seeAlsoToggle" onclick="OpenSection(seeAlsoToggle)">See Also</a>
<a id="exampleSectionLink" href="#codeExampleToggle" onclick="OpenSection(codeExampleToggle)">Example</a>
</td>
</tr>
</table>
<table width="100%" id="bottomTable" cellspacing="0" cellpadding="0" style="display:none">
<tr>
<td>
<span onclick="ExpandCollapseAll(toggleAllImage)" style="cursor:default;" onkeypress="ExpandCollapseAll_CheckKey(toggleAllImage)" tabindex="0">
<img ID="toggleAllImage" class="toggleAll" src="collall.gif" />
<label id="collapseAllLabel" for="toggleAllImage" style="display: none;">
Collapse All
</label>
<label id="expandAllLabel" for="toggleAllImage" style="display: none;">
Expand All
</label>
</span>
</td>
</tr>
</table>
</div>
<div id="mainSection">
<div id="mainBody">
<h1 class="heading">
SQL As Understood By SQLite</h1>
<p>
The SQLite library understands most of the standard SQL language. But it does omit
some features while at the same time adding a few features of its own. This document
attempts to describe precisely what parts of the SQL language SQLite does and does
not support. A list of keywords is also provided. In all of the syntax diagrams
that follow, literal text is shown in bold blue. Non-terminal symbols are shown
in italic red. Operators that are part of the syntactic markup itself are shown
in black roman. This document is just an overview of the SQL syntax implemented
by SQLite.
</p>
<h4>
SQLite implements the follow syntax:</h4>
<p>
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse">
<tr>
<td>
<a href="lang_altertable.html">
ALTER TABLE</a></td>
</tr>
<tr>
<td>
<a href="lang_analyze.html">
ANALYZE</a></td>
</tr>
<tr>
<td style="height: 19px">
<a href="lang_attach.html">
ATTACH DATABASE</a></td>
</tr>
<tr>
<td>
<a href="lang_transaction.html">
BEGIN TRANSACTION</a></td>
</tr>
<tr>
<td>
<a href="lang_comment.html">
comment</a></td>
</tr>
<tr>
<td>
<a href="lang_transaction.html">
COMMIT TRANSACTION</a></td>
</tr>
<tr>
<td>
<a href="lang_createindex.html">CREATE INDEX</a></td>
</tr>
<tr>
<td>
<a href="lang_createtable.html">CREATE TABLE</a></td>
</tr>
<tr>
<td>
<a href="lang_createtrigger.html">CREATE TRIGGER</a></td>
</tr>
<tr>
<td>
<a href="lang_createview.html">CREATE VIEW</a></td>
</tr>
<tr>
<td>
<a href="lang_createvtab.html">
CREATE VIRTUAL TABLE</a></td>
</tr>
<tr>
<td>
<a href="lang_delete.html">
DELETE</a></td>
</tr>
<tr>
<td>
<a href="lang_detach.html">
DETACH DATABASE</a></td>
</tr>
<tr>
<td>
<a href="lang_dropindex.html">DROP INDEX</a></td>
</tr>
<tr>
<td>
<a href="lang_droptable.html">DROP TABLE</a></td>
</tr>
<tr>
<td>
<a href="lang_droptrigger.html">DROP TRIGGER</a></td>
</tr>
<tr>
<td>
<a href="lang_dropview.html">DROP VIEW</a></td>
</tr>
<tr>
<td>
<a href="lang_transaction.html">
END TRANSACTION</a></td>
</tr>
<tr>
<td>
<a href="lang_explain.html">
EXPLAIN</a></td>
</tr>
<tr>
<td>
<a href="lang_expr.html">
expression</a></td>
</tr>
<tr>
<td>
<a href="lang_insert.html">
INSERT</a></td>
</tr>
<tr>
<td>
<a href="lang_conflict.html">
ON CONFLICT clause</a></td>
</tr>
<tr>
<td style="height: 19px">
<a href="pragma.html">
PRAGMA</a></td>
</tr>
<tr>
<td>
<a href="lang_reindex.html">
REINDEX</a></td>
</tr>
<tr>
<td>
<a href="lang_replace.html">
REPLACE</a></td>
</tr>
<tr>
<td>
<a href="lang_transaction.html">
ROLLBACK TRANSACTION</a></td>
</tr>
<tr>
<td>
<a href="lang_select.html">
SELECT</a></td>
</tr>
<tr>
<td>
<a href="lang_update.html">
UPDATE</a></td>
</tr>
<tr>
<td>
<a href="lang_vacuum.html">
VACUUM</a></td>
</tr>
</table>
</p>
<hr>
<div id="footer">
<p>
</p>
<p>
</p>
</div>
</div>
</div>
</body>
</html>