beautypg.com

Google Search Appliance Protocol Reference User Manual

Page 44

background image

Google Search Appliance: Search Protocol Reference

Request Format

44

Examples

Example 1:

The following search request returns the first 10 results that match the query “checks” in the “test”
collection and also contain either of the following meta tags (the %2520 operator in the GET statement
shows double encoding where %20 (space) is double encoded so that the % character (hexadecimal 25)
is appended to the hexadecimal 20):


GET /search?q=checks&output=xml&client=test

&site=test
&requiredfields=department:Human%2520Resources|dep

artment:Finance

Example 2:

The following search returns the first 10 results that match the query “checks” in the “test” collection
that do NOT contain the following meta tag:

GET //search?q=checks&output=xml&client=test

&site=test
&requiredfields=-department:Engineering

Example 3:

The following search request returns the first 10 results that match the query “books” in the “test”
collection, and also contain the word “Scott” somewhere in the “author” meta tag. Some example meta
tags that satisfy this search request are:


GET /search?q=books&output=xml

&client=test
&site=test
&partialfields=author:Scott

Details

Multiple meta tag constraints can be specified using the requiredfields and partialfields
parameters. To filter for the presence of a meta tag, indicate the name of the meta tag to be found. To
filter on a specific meta tag value, indicate the name of the meta tag followed by the colon “:” character
and then the specific value. The partialfields parameter matches complete words, not parts of
words.

To combine multiple name-value pairs, use the following Boolean operators.

Boolean OR [ | ]

Returns results that satisfy either meta tag constraint.

Example: department:Sales|department:Finance