annotate sqlite.xml @ 8:51847f1c0acb draft default tip

Uploaded
author sem4j
date Mon, 30 Sep 2013 04:09:36 -0400
parents 9e9da6cf492b
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
1 <tool id="sqlite" name="SQL" version="0.4">
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
2 <description>Runner (SQLite)</description>
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
3 <command interpreter="python">
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
4 sqlite.py $output_file $explain_plan $header "$sql"
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
5 #for $i in $files
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
6 ${i.file} ${i.header} '${i.index}'
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
7 #end for
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
8 </command>
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
9 <inputs>
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
10 <repeat name="files" title="Table">
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
11 <param name="file" type="data" format="tabular" label="File (tabular)"/>
8
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
12 <param name="header" type="boolean" truevalue="1" falsevalue="0" checked="False" label="Use the first row as column names (If unchecked, use c1 c2 c3 ...)" />
0
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
13 <param name="index" type="text" size='20' value="" label="Index" />
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
14 </repeat>
8
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
15 <param name="header" type="boolean" truevalue="1" falsevalue="0" checked="False" label="Print column names in the first row" />
0
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
16 <param name="sql" type="text" area="true" size="10x50" label="SQL">
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
17 <sanitizer sanitize="False"/>
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
18 </param>
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
19 <param name="explain_plan" type="boolean" truevalue="1" falsevalue="0" checked="False" label="Explain SQL execution plan. (Ignore if you are not a developer)" />
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
20 </inputs>
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
21 <outputs>
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
22 <data name="output_file" format="tabular" label="${tool.name} on ${on_string}"/>
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
23 </outputs>
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
24 <help>
8
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
25
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
26 **Tables**
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
27
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
28 Select all table to be joined.
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
29
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
30 ----
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
31
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
32 **Use the first line as column names**
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
33
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
34 When the input file has column header::
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
35
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
36 id name
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
37 101 John
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
38 102 Mary
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
39
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
40 Check this box and use column names ('id' and 'name') to write queries:
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
41
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
42 SELECT * FROM t1 WHERE c2 = 'John';
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
43
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
44 When the input file does not have column header::
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
45
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
46 101 John
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
47 102 Mary
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
48
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
49 Uncheck this box and use c1, c2, c3, ... to write queries:
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
50
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
51 SELECT * FROM t1 WHERE name = 'John';
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
52
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
53 ----
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
54
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
55 **Index**
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
56
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
57 Comma-delimited list of column numbers.
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
58
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
59 Example:
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
60
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
61 2,3
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
62
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
63 This creates NOT a composite index BUT two different indices on column 2 and on column 3.
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
64
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
65 ----
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
66
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
67 **Print column names in the first row**
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
68
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
69 Example::
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
70
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
71 col1 col2 col3
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
72 aaaa bbbb cccc
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
73 aaaa dddd eeee
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
74
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
75 ----
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
76
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
77 **SQL**
51847f1c0acb Uploaded
sem4j
parents: 0
diff changeset
78
0
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
79 </help>
9e9da6cf492b Uploaded
sem4j
parents:
diff changeset
80 </tool>