Restore namazu template files.
[mharc.git] / cgi-bin / template / NMZ.body.in.dist
CommitLineData
bfab7d84
IK
1<h2><a name="query">Query</a></h2>
2
3<h3><a name="query-term">Single term query</a></h3>
4<p>
5The query specifies only one term for retrieving all
6documents which contain the term. e.g.,
7</p>
8
9<p class="example">
10namazu
11</p>
12
13<h3><a name="query-and">AND query</a></h3>
14
15<p>
16The query specifies two or more terms for retrieving all
17documents which contain both terms. You can insert the
18<code class="operator">and</code> operator between the terms. e.g.,
19</p>
20
21<p class="example">
22Linux and Netscape
23</p>
24
25<p>
26You can ommit the <code class="operator">and</code> operator. Terms which is
27separated by one ore more spaces is assumed to be AND query.
28</p>
29
30<h3><a name="query-or">OR query</a></h3>
31<p>
32The query specifies two or more terms for retrieving all
33documents which contain either term. You can insert the
34<code class="operator">or</code> operator between the terms.
35e.g.,
36</p>
37
38<p class="example">
39Linux or FreeBSD
40</p>
41
42<h3><a name="query-not">NOT query</a></h3>
43<p>
44The query specifies two or more terms for retrieving all
45documents which contain a first term but does't contain the
46following terms. You can insert the <code class="operator">not</code>
47operator between the terms to do NOT query. e.g.,
48</p>
49
50<p class="example">
51Linux not UNIX
52</p>
53
54
55<h3><a name="query-grouping">Grouping</a></h3>
56<p>
57You can group queries by surrounding them by
58parentheses. The parentheses should be separated by one or
59more spaces. e.g.,
60</p>
61
62<p class="example">
63( Linux or FreeBSD ) and Netscape not Windows
64</p>
65
66<h3><a name="query-phrase">Phrase searching</a></h3>
67<p>
68You can search for a phrase which consists of two or more terms
69by surrounding them with double quotes like
70<code class="operator">"..."</code> or with braces like <code class="operator">{...}</code>.
71In Namazu, precision of phrase searching is not 100 %,
72so it causes wrong results occasionally. e.g.,
73</p>
74
75<p class="example">
76{GNU Emacs}
77</p>
78
79<!-- foo
80<p>
81You must choose the latter with Tkanamzu or namazu.el.
82</p>
83-->
84
85<h3><a name="query-substring">Substring matching</a></h3>
86<p>
87The are three types of substring matching searching.
88</p>
89
90<dl>
91<dt>Prefix matching
92<dd><code class="example">inter*</code> (terms which begin with <code>inter</code>)
93<dt>Inside matching
94<dd><code class="example">*text*</code> (terms which contain <code>text</code>)
95<dt>Suffix matching
96<dd><code class="example">*net</code> (terms which terminated
97with <code>net</code>)
98</dl>
99
100
101<h3><a name="query-regex">Regular expressions</a></h3>
102
103<p>
104You can use regular expressions for pattern matching. The
105regular expressions must be surrounded by slashes like <code
106class="operator">/.../</code>. Namazu uses <a
107href="http://www.ruby-lang.org/">Ruby</a>'s regular
108regular expressions engine. It offers generally <a
109href="http://www.perl.com/">Perl</a> compatible flavor.
110e.g.,
111</p>
112
113<p class="example">
114/pro(gram|blem)s?/
115</p>
116
117
118<h3><a name="query-field">Field-specified searching</a></h3>
119<p>
120You can limit your search to specific fields such as
121<code>Subject:</code>, <code>From:</code>,
122<code>Message-Id:</code>. It's especially convenient for
123Mail/News documents. e.g.,
124</p>
125
126<ul>
127<li><code class="example">+subject:Linux</code><br>
128(Retrieving all documents which contain <code>Linux</code>
129in a <code>Subject:</code> field)
130
131<li><code class="example">+subject:"GNU Emacs"</code><br>
132(Retrieving all documents which contain <code>GNU Emacs</code>
133in a <code>Subject:</code> field)
134
135<li><code class="example">+from:foo@bar.jp</code><br>
136(Retrieving all documents which contain <code>foo@bar.jp</code>
137in a <code>From:</code> field)
138
139
140<li><code class="example">+message-id:&lt;199801240555.OAA18737@foo.bar.jp&gt;</code><br>
141(Retrieving a certain document which contains specified
142<code>Message-Id:</code>)
143</ul>
144
145<h3><a name="query-notes">Notes</a></h3>
146
147<ul>
148<li>In any queries, Namazu ignores case distinctions of
149alphabet characters. In other words, Namazu does
150case-insensitive pattern matching in any time.
151
152
153<li>Japanese phrases are forced to be segmented into
154morphemes automatically and are handled them as <a
155href="#query-phrase">phrase searching</a>. This processing
156causes invalid segmentation occasionally.
157
158
159<li>Alphabet, numbers or a part of symbols (duplicated in
160ASCII) characters which defined in JIS X 0208 (Japanese
161Industrial Standards) are handled as ASCII characters.
162
163<li>Namazu can handle a term which contains symbols like
164<code>TCP/IP</code>. Since this handling isn't complete,
165you can describe <code>TCP and IP</code> instead of
166<code>TCP/IP</code>, but it may cause noisy results.
167
168
169<li>Substring matching and field-specified searching takes
170more time than other methods.
171
172<li>If you want to use <code class="operator">and</code>,
173<code class="operator">or</code> or <code
174class="operator">not</code> simply as terms, you can
175surround them respectively with double quotes like <code
176class="operator">"..."</code> or braces like <code
177class="operator">{...}</code>.
178
179<!-- foo
180You must choose the latter with Tkanamzu or namazu.el.
181-->
182
183</ul>
184