1
<html xmlns="http://www.w3.org/1999/xhtml">
3
<script src="../../js/codemirror.js" type="text/javascript"></script>
4
<title>CodeMirror: SQL demonstration</title>
5
<link rel="stylesheet" type="text/css" href="../../css/docs.css"/>
7
<body style="padding: 20px;">
9
<p>Demonstration of <a href="index.html">CodeMirror</a>'s SQL
12
<p>Written by John Benediktsson (<a href="LICENSE">license</a>).</p>
15
<textarea id="code" cols="120" rows="50">
16
create table if not exists table1(
17
a bigint(13) not null primary key,
23
insert into table1 values (1234567890123, "b", "c", 0);
25
select from_unixtime(a/1000), b, c, min(d) as `using`
27
left join table2 t2 using (a)
28
-- inner join table3 t3 on t3._a = t1.a
32
) as foo on foo.a = t1.a
41
select @total := sum(d) from data;
45
<script type="text/javascript">
46
var editor = CodeMirror.fromTextArea('code', {
48
parserfile: "../contrib/sql/js/parsesql.js",
49
stylesheet: "css/sqlcolors.css",