blob: 788de85a57dba7ed307a2bc70094ed826c2e0977 [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<FilteredQuery>
<Query>
<BooleanQuery fieldName="contents">
<Clause occurs="should">
<TermQuery>merger</TermQuery>
</Clause>
<Clause occurs="must">
<TermQuery>bank</TermQuery>
</Clause>
</BooleanQuery>
</Query>
<Filter>
<!-- TermsFilter uses an analyzer to tokenize Field text and creates a filter for docs which
have ANY of the supplied terms. Unlike a RangeFilter this can be used for filtering on
multiple terms that are not necessarily in a sequence. An example might be a list of primary
keys from a database query result or perhaps a choice of "category" labels picked by the end
user.
As a filter, this is much faster than the equivalent query (a BooleanQuery with many
"should" TermQueries)
This example might be just a list of Saturdays ie not a contiguous range of values
which can be handled by rangefilter
-->
<TermsFilter fieldName="date">
19870601 19870608 19870615
</TermsFilter>
</Filter>
</FilteredQuery>