Sie sind auf Seite 1von 20

Contents

Bing Query Language ...................................................................................................................... 5


How the Documentation is Organized ......................................................................................... 5
About Bing Query Language ........................................................................................................... 5
About Bing Advanced Operator Syntax ....................................................................................... 5
Applicable Environments .......................................................................................................... 5
Operator Precedence ...................................................................................................................... 6
Precedence Logic......................................................................................................................... 6
Examples...................................................................................................................................... 6
Advanced Operator Reference ........................................................................................................ 6
altloc: ............................................................................................................................................... 6
Example ....................................................................................................................................... 7
Remarks ....................................................................................................................................... 7
See Also ....................................................................................................................................... 7
AND ................................................................................................................................................. 7
Example ....................................................................................................................................... 7
Remarks ....................................................................................................................................... 7
See Also ....................................................................................................................................... 7
contains: .......................................................................................................................................... 7
Example ....................................................................................................................................... 8
define ............................................................................................................................................... 8
Example ....................................................................................................................................... 8
domain: ............................................................................................................................................ 8
Example ....................................................................................................................................... 8
Remarks ....................................................................................................................................... 8
feed: ................................................................................................................................................. 8
Example ....................................................................................................................................... 8
Remarks ....................................................................................................................................... 8
filetype: ............................................................................................................................................ 9
Example ....................................................................................................................................... 9
hasfeed: ........................................................................................................................................... 9
Example ....................................................................................................................................... 9

imagesize: ........................................................................................................................................ 9
Example ....................................................................................................................................... 9
Remarks ....................................................................................................................................... 9
inanchor: ........................................................................................................................................ 10
Example ..................................................................................................................................... 10
Remarks ..................................................................................................................................... 10
inbody: ........................................................................................................................................... 10
Example ..................................................................................................................................... 10
Remarks ..................................................................................................................................... 10
instreamset: ................................................................................................................................... 10
Example ..................................................................................................................................... 10
Remarks ..................................................................................................................................... 10
intitle: ............................................................................................................................................. 11
Example ..................................................................................................................................... 11
See Also ..................................................................................................................................... 11
ip: ................................................................................................................................................... 11
Example ..................................................................................................................................... 11
Remarks ..................................................................................................................................... 11
keyword ......................................................................................................................................... 11
Example ..................................................................................................................................... 11
Remarks ..................................................................................................................................... 11
language: ....................................................................................................................................... 12
Example ..................................................................................................................................... 12
Remarks ..................................................................................................................................... 12
literalmeta: ..................................................................................................................................... 12
Example ..................................................................................................................................... 12
Remarks ..................................................................................................................................... 12
loc: ................................................................................................................................................. 12
Example ..................................................................................................................................... 12
Remarks ..................................................................................................................................... 12
See Also ..................................................................................................................................... 13
location: ......................................................................................................................................... 13
Example ..................................................................................................................................... 13
Remarks ..................................................................................................................................... 13
See Also ..................................................................................................................................... 13
meta: .............................................................................................................................................. 13

Example ..................................................................................................................................... 13
Remarks ..................................................................................................................................... 13
msite: ............................................................................................................................................. 14
Example ..................................................................................................................................... 14
near: ............................................................................................................................................... 14
Example ..................................................................................................................................... 14
Remarks ..................................................................................................................................... 14
noalter: ........................................................................................................................................... 14
Example ..................................................................................................................................... 14
Remarks ..................................................................................................................................... 14
norelax: .......................................................................................................................................... 15
Example ..................................................................................................................................... 15
Remarks ..................................................................................................................................... 15
NOT ............................................................................................................................................... 15
Example ..................................................................................................................................... 15
See Also ..................................................................................................................................... 15
OR ................................................................................................................................................. 15
Example ..................................................................................................................................... 15
See Also ..................................................................................................................................... 16
site: ................................................................................................................................................ 16
Example ..................................................................................................................................... 16
Remarks ..................................................................................................................................... 16
url: .................................................................................................................................................. 16
Example ..................................................................................................................................... 16
- 16
Section Heading ......................................................................................................................... 16
See Also ..................................................................................................................................... 16
& 17
Example ..................................................................................................................................... 17
Remarks ..................................................................................................................................... 17
See Also ..................................................................................................................................... 17
&& .................................................................................................................................................. 17
Example ..................................................................................................................................... 17
Remarks ..................................................................................................................................... 17
See Also ..................................................................................................................................... 17

( 18
Examples.................................................................................................................................... 18
Remarks ..................................................................................................................................... 18
See Also ..................................................................................................................................... 18
) 18
Examples.................................................................................................................................... 18
Remarks ..................................................................................................................................... 18
See Also ..................................................................................................................................... 18
: 19
Example ..................................................................................................................................... 19
| 19
Example ..................................................................................................................................... 19
Remarks ..................................................................................................................................... 19
See Also ..................................................................................................................................... 19
|| 19
Example ..................................................................................................................................... 19
Remarks ..................................................................................................................................... 19
See Also ..................................................................................................................................... 20
"phrase ......................................................................................................................................... 20
Example ..................................................................................................................................... 20

Bing Query Language


Bing Query Language enables the incorporation of advanced operator syntax in requests sent to
Bing Application Programming Interfaces. Advanced operator syntax is syntax that enables you to
refine a query. This document provides you with the resources necessary to use this syntax.

How the Documentation is Organized


This documentation is organized with the intent of giving general overview information about Bing
Query Language and detailed information about individual operators.

Section

Provides

About Bing Query Language

An overview of Bing Query Language

Advanced Operator Reference

Information about Advanced Operator Syntax

About Bing Query Language


This topic provides overview information about Bing and Bing Advanced Operator Syntax.

About Bing Advanced Operator Syntax


Bing Advanced Operator Syntax enables the incorporation of advanced operator syntax in
requests sent to Bing Application Programming Interfaces. Advanced operator syntax is language
that enables you to refine a query.

Applicable Environments
Except where specified otherwise, Bing Advanced Operator Syntax works in the following
environments:

Bing Search Engine Results Page

Bing Application Programming Interface

Operator Precedence
Precedence is the concept that Bing evaluates the action of some operators before evaluating the
action of other operators.

Precedence Logic
() has highest precedence.
AND, &&, and & have higher precedence than OR, |, and ||.

Examples
foo bar OR bing yahoo

is the same as
(foo AND bar) | (bing AND yahoo)

instead of
foo (bar | bing) yahoo

Similarly,
foo AND bar NOT hello

is equivalent to
(foo AND bar) NOT hello
foo OR bar NOT hello

is equivalent to
(foo OR bar) NOT hello

Advanced Operator Reference


For each operator, the corresponding topic specifies:

Operator Name

Description

Example (if appropriate)

altloc:
Used to specify a local search that is outside major markets.

Example
lang:pt AND (altloc:br OR loc:br)

Remarks
pt-us typically gets indexed as lang:pt loc:us, but in this example it would get indexed as
lang:pt loc:us altloc:br altloc:pt. The altloc: locations are derived from major markets for the
given language (pt-br and pt-pt in the case of this example). For more information about
language codes, see Bing API Documentation.

See Also
Bing API Documentation

AND
Finds webpages that contain all the terms or phrases in a query. By default, all searches are
AND; that is, the search returns webpages that contain all the terms or phrases in the query.
Case-sensitive; if all the query terms are uppercase, AND is not treated as an operator.

Example
Foo AND bar

Remarks
AND has precedence over OR.

See Also
&
&&
Operator Precedence

contains:
Keeps results focused on sites that have links to the file types that you specify.

Example
surfing contains:pdf

define
Triggers an Instant Answer definition for the specified word.

Example
define gravity

domain:
Limits results to the specified domain.

Example
domain:www.blueberry.com

Remarks
domain: also returns any suffix matches; in the example, home.www.blueberry.com could also
be returned. While domain: searches all suffix matches, site: searches up to two levels only. IP
address cannot be used with domain:.

feed:
Finds RSS or Atom feeds pertaining to the term you specify.

Example
feed:surfing

Remarks
RSS (Really Simple Syndication) is a publishing format that websites use to easily distribute, or
syndicate, content to a wide audience. You can add RSS feeds to an RSS reader to make finding
news easier. Some RSS readers are web-based, while other readers are separate downloads
that run on your computer.
8

filetype:
Returns only webpages of the specified file type.

Example
surfing filetype:pdf

hasfeed:
Finds webpages that contain both the term or terms for which you are querying and one or more
RSS or Atom feeds.

Example
site:www.nytimes.com hasfeed:surfing

imagesize:
Constrains the size of returned images.

Example
dogs imagesize:large

Remarks
For image search only. Valid values are:

Value

Constraint

Small

Both width and height are less than 200 pixels.

Medium

Both width and height are between 200 pixels


and 500 pixels.

Large

Both width and height are greater than 200


pixels.

inanchor:
Returns webpages that contain the specified term in the anchor text.

Example
inanchor:birdwatching

Remarks
Word order is preserved; for example, inanchor:bird watching would search for bird before
watching in anchor text.

inbody:
Returns webpages that contain the specified term in the metadata or in the HTML body.

Example
inbody:spaces inbody:magog

Remarks
Inbody:spaces magog is a valid but different example, as it is a phrase match.

instreamset:
Checks to see if a string is present with one or more properties.

Example
instreamset:(url title):foo

Remarks
This is a more generic version of intitle:, inbody:, and inanchor: - any of these meta tags can be
specified within the parentheses.

10

intitle:
Returns webpages that contain the specified term in the metadata title of the site.

Example
intitle:surfing

See Also
instreamset:

ip:
Finds sites that are hosted by a specific IP address. The IP address must be a dotted quad
address. Type the ip: keyword, followed by the IP address of the website.

Example
ip:207.46.197.32

Remarks
Prefix-matching is also possible, that is, ip:46 would return the site IP:46.249.252.39 if the latter
is in the index.

keyword
Metaoperator; that is, an operator that is used with other operators. Takes a simple list as a
parameter. All the elements in the list are ORed together.

Example
keyword:(intitle inbody)software

Remarks
This example is equivalent to intitle:software OR inbody:software.

11

language:
Returns webpages written in a specific language. Specify the language code directly after the
language: keyword. For valid language codes, see Bing API Version 2 Documentation.

Example
food language:es

Remarks
You can also access this functionality by way of Bing Search Builder. To use Search Builder, click
Advanced Search on any Bing results page.

literalmeta:
Any string within parentheses is interpreted literally; that is, with no word-breaking or symbolic
interpretation.

Example
literalmeta:foo(hello)

Remarks
In the example, pages for which the metatag foo contains the word bar would be returned.

loc:
Returns webpages from a specific country or region. Specify the country or region code directly
after the loc: keyword. For language codes, see Bing API Version 2 Documentation. To return
results for two or more languages, use OR to group the languages.

Example
football loc:ES

Remarks
This operator is not available for all languages.
12

Same as the location: operator.

See Also
location:

location:
Returns webpages from a specific country or region. Specify the country or region code directly
after the location: keyword. For language codes, see Bing API Version 2 Documentation. To
return results for two or more languages, use OR to group the languages.

Example
football location:ES

Remarks
This operator is not available for all languages.
Same as the loc: operator.

See Also
loc:

meta:
Allows the filtering of content based on special tags in HTML.

Example
meta:Search.os("Windows 7")

Remarks
This example takes advantage of the fact that all Windows 7 pages include the meta: tag meta:Search.os("Windows 7"). When a user searches from the Windows7 help client, Bing
automatically filters the content by adding meta:Search.os("Windows 7") to the query.

13

msite:
Source filtering used to refine a query for a multimedia site. Used for both Image and Video
SourceTypes.

Example
msite:hulu.com simpsons

near:
Constrains the distance between terms so that documents that contain instances of the specified
terms within ten words of each other are returned before those that dont.

Example
foo near:10 bar

Remarks
Ordering is considered in ranking. Thus, in this example, pages that contain bar ten words or less
after foo would receive a greater boost in rank than pages in which foo appears ten words or less
after bar. However, depending on the rest of the query, this does not necessarily mean that the
former would be ranked higher than the latter.

noalter:
Disables alteration service.

Example
noalter: foo bar

Remarks
noalter: has no arguments; it applies to the entire query, indicating to the Alteration Service to
keep the query as is.

14

norelax:
Only allow search word, phrase or word: in the constraint. Bing implements relaxcount for a 5+
word query by default; that is, the fifth word in a query and subsequent appears do not
necessarily appear in results.

Example
cry for you lyrics norelax:September

Remarks
The effect of the syntax in this example is to specify that all returned results must contain
september. In the absence of the norelax: operator, since there are 5 words in the query, Bing
would augment with a relaxcount=+1, that could return documents that do not contain
september.

NOT
Excludes webpages that contain the specified term or terms.

Example
climbing NOT rock

See Also
Operator Precedence

OR
Finds webpages that contain either the term that precedes the operator or the term that follows
the operator. Same as | and ||.

Example
foo OR bar

15

See Also
|
||

site:
Returns webpages that belong to the specified site.

Example
"heart disease" (site:bbc.co.uk OR site:cnn.com)

Remarks
To focus on two or more domains, use OR to group the domains. You can use site: to search for
web domains, top level domains, and directories that are not more than two levels deep. You can
also search for webpages that contain a specific search word on a site.

url:
Returns results that indicate whether the specified domain or URL is in the Bing Index.

Example
url:microsoft.com

Excludes webpages that contain a term or phrase (same as NOT).

Section Heading
color -red

See Also
NOT

16

&
Finds webpages that contain all the terms or phrases in a query. Same as AND and &&.

Example
foo & bar
foo& bar
foo &bar

Remarks
Each of the examples is equivalent to foo AND bar. Note, however, that foo&bar is equivalent to
foo bar. This is because, when no spaces are present, & functions as a stopword, that is, a
character that terminates a word. Bing Wordbreaker functionality then removes &.

See Also
AND
&&

&&
Finds webpages that contain all the terms or phrases in a query.

Example
Foo && bar

Remarks
Same as AND and &.

See Also
AND
&

17

(
In combination with ), operator for term separation and precedence.

Examples
As Operator:
foo(bar)blue
As Literal:
foo(bar)blue

Remarks
The Operator example is equivalent to foo AND bar AND blue.

See Also
)

)
In combination with (, operator for term separation and precedence.

Examples
As Operator:
foo(bar)blue
As Literal:
foo(bar)blue

Remarks
The Operator example is equivalent to foo AND bar AND blue.

See Also
(

18

:
Used to separate keywords and values.

Example
domain:www.blueberry.com

|
Finds webpages that contain either the term that precedes the operator or the term that follows
the operator.

Example
foo OR bar

Remarks
Same as OR and ||

See Also
OR
||

||
Finds webpages that contain either the term that precedes the operator or the term that follows
the operator.

Example
foo || bar

Remarks
Same as OR and |

19

See Also
OR
|

"phrase
Returns results that contain the specified phrase, exactly.

Example
foo

20

Das könnte Ihnen auch gefallen