brandwatch masterclass: basic query writing
DESCRIPTION
NY Masterclass Session, May 8TRANSCRIPT
Brandwatch Masterclass/Basic Query WritingAlyssa Edelman
[email protected] | Brandwatch Masterclass | May 2014
Agenda
© 2013 Brandwatch | www.brandwatch.com 2
•Introduction to Queries
•Introduction to Boolean Search
•“Home Base” Operators
•Other Useful Operators
•Query Writing Game!
3
The Brandwatch Query
© 2013 Brandwatch | www.brandwatch.com
What is a Query?
© 2014 Brandwatch | www.brandwatch.com 4
Queries are specialized Web searches. They rely on Boolean Operators to link together keywords.
Queries return mentions, which can be a Tweet, Facebook post, blog post, forum post, or any other Web-based post that matches your search.
These mentions, once pulled in to Brandwatch with a query, can be visualized on a dashboard.
Queries are always running in the background, bringing new data in to the app as new content is created and made public across the Web.
© 2013 Brandwatch | www.brandwatch.com 5
Defining Boolean
Operators
Boolean 101
© 2014 Brandwatch | www.brandwatch.com 6
“A type of search allowing users to combine keywords with operators such as AND, NOT, and OR to further produce more relevant results.”
Boolean operators help limit a search to help find the information that’s most meaningful. Think of them as conjunctions.
Did you know? You can use Boolean search terms on Google!
© 2013 Brandwatch | www.brandwatch.com 7
Basic Operators
What are your Go-To Operators?
© 2014 Brandwatch | www.brandwatch.com 8
These are your most basic operators: AND, OR, and NOT
These must be capitalized to work within a query.
To use these as an actual keyword in your search, they must be in quotes or you’ll receive an error message.
© 2014 Brandwatch | www.brandwatch.com 9
AND
AND
© 2014 Brandwatch | www.brandwatch.com 10
Linking search terms with an AND operator will look for mentions that include both the first term and the second term anywhere within the mention.
Always use the Test Query button to preview the results the query, as written, will return.
© 2014 Brandwatch | www.brandwatch.com 11
© 2014 Brandwatch | www.brandwatch.com 12
© 2014 Brandwatch | www.brandwatch.com 13
OR
OR
© 2014 Brandwatch | www.brandwatch.com 14
Linking search terms with an OR operator will look for mentions that include either the first term or the second term.
© 2014 Brandwatch | www.brandwatch.com 15
NOT
NOT
© 2014 Brandwatch | www.brandwatch.com 16
Linking search terms with a NOT operator will look for mentions that include the first term, but not the second term.
© 2014 Brandwatch | www.brandwatch.com 17
Using Quotes and
Parentheses
Quotes and Parentheses (Brackets)
© 2014 Brandwatch | www.brandwatch.com 18
Quotes are used to group together two or more words that should be searched for together as part of a phrase.
• “corgi puppies” will search for mentions of corgi puppies
• corgi puppies will be recognized as corgi AND puppies
Parentheses are used to group together search terms and operators to created more sophisticated, targeted queries.
© 2014 Brandwatch | www.brandwatch.com 19
© 2014 Brandwatch | www.brandwatch.com 20
© 2014 Brandwatch | www.brandwatch.com 21
© 2013 Brandwatch | www.brandwatch.com 22
Other Useful Operators
© 2014 Brandwatch | www.brandwatch.com 23
NEAR/x and NEAR/xf
NEAR/x and NEAR/xf
© 2014 Brandwatch | www.brandwatch.com 24
The NEAR operator is used to find keywords within x number of words of each other.
Adding a lowercase f at the end searches for the keywords in the order you’ve written them.
This leads to more targeted results than the AND operator.
© 2014 Brandwatch | www.brandwatch.com 25
© 2014 Brandwatch | www.brandwatch.com 26
© 2014 Brandwatch | www.brandwatch.com 27
raw:
raw:
© 2014 Brandwatch | www.brandwatch.com 28
The raw: operator is used in front of a keyword versus between keywords (as is any operator with a :).
Any search terms written after a raw: operator will be searched for exactly as written, so if symbols ($, %, !) or letter case (a versus A) are important to your search, use it!
You can use parentheses with an OR operator between keywords to link together keywords you’re searching for:
raw:(LOVE OR HATE OR FastPass OR iPhone)
© 2014 Brandwatch | www.brandwatch.com 29
© 2014 Brandwatch | www.brandwatch.com 30
hashtags:
hashtags:
© 2014 Brandwatch | www.brandwatch.com 31
This is one of the newest operators at Brandwatch!
The hashtags: operator will search for any keywords you put after it that are preceded by a # symbol.
You do not need to write the # symbol when using the hashtags: operator.
You can use parentheses with an OR operator between keywords to link together hashtags you’re searching for:
hashtags:(puppies OR corgis OR ilovepuppies)
© 2014 Brandwatch | www.brandwatch.com 32
© 2014 Brandwatch | www.brandwatch.com 33
Wildcards
Wildcards: * and ?
© 2014 Brandwatch | www.brandwatch.com 34
Adding a * to the end of a keyword will add any appropriate suffixes to the keyword when searching:
pupp* would search for puppy, puppies, puppying?
The ? wildcard is used within a word to account for spelling variations and common misspellings:
prioriti?e would search for prioritize and prioritise
© 2014 Brandwatch | www.brandwatch.com 35
© 2014 Brandwatch | www.brandwatch.com 36
© 2014 Brandwatch | www.brandwatch.com 37
Location
Location
Narrow down your results to continent, country, city, state, or county
Use the Locations drop-down to search for the abbreviation and copy/paste into your query
© 2014 Brandwatch | www.brandwatch.com 38
© 2014 Brandwatch | www.brandwatch.com 39
Recap
© 2014 Brandwatch | www.brandwatch.com 40
Key Takeaways
•Queries are elaborate Web searches
•AND, OR, and NOT are your go-to operators
•Use quotation marks around search terms that are more than one word, and parenthesis to group together search terms
•Clicking “List of Operators” will open a handy quick-reference guide
© 2014 Brandwatch | www.brandwatch.com 41
© 2014 Brandwatch | www.brandwatch.com 42
Query Writing Game!
© 2014 Brandwatch | www.brandwatch.com 43
Write a query that searches for both strawberries and Florida oranges.
Write a query that looks for strawberries and oranges, but not bananas.
Write a query that searches for people who HATE bananas.
Write a query that searches for people who are talking about picking strawberries (or strawberry picking) in Florida. (use location filter or keyword search)
Write a query that looks for #strawberry, #floridaorange, or #banana, but not #gross or #ew
Write a query that searches for both strawberries and Florida oranges.
strawberries AND “florida oranges”
© 2014 Brandwatch | www.brandwatch.com 44
Write a query that looks for strawberries and oranges, but not bananas.
(strawberries AND oranges) NOT bananas
© 2014 Brandwatch | www.brandwatch.com 45
Write a query that searches for people who HATE bananas.
bananas AND raw:HATE
© 2014 Brandwatch | www.brandwatch.com 46
Write a query that searches for people who are talking about picking strawberries (or
strawberry picking) in Florida.(“picking strawberries” OR “strawberry picking”) AND florida
(“picking strawberries” OR “strawberry picking”) AND state:flof
((strawberry OR strawberries) NEAR/0 picking) AND florida
((strawberry OR strawberries) NEAR/0 picking) AND state:flof
((strawberr*) NEAR/0 picking) AND (state:flof OR florida)
© 2014 Brandwatch | www.brandwatch.com 47
Write a query that looks for #strawberry, #floridaorange, and #banana, but not #gross
or #ew.
(hashtags:(strawberry OR floridaorange OR banana)) NOT hashtags:ew
© 2014 Brandwatch | www.brandwatch.com 48