Supported operators for Story Query
Updated
Below is the list of all the supported operators which you can utilize to form a Story Query. To understand in detail about operators and how they function, refer to Operators FAQs.
Operator | Example | Description |
AND | social AND sprinklr | Search for keywords "social" and "sprinklr" anywhere within the complete message. Both keywords MUST be there for a match. |
OR | "Customer experience" OR sprinklr | Search for keywords "Customer experience" or "sprinklr" anywhere within a complete message. One of the keywords must be there for a match. |
NOT | "Sprinklr" NOT "Stocks" | Search for results that contain the keyword "Sprinklr" but should not contain the keyword "Stocks". |
Proximity | "social media"~10 | Search for keywords "social" and "media" within 10 words of each other. |
NEAR | ((Apple) NEAR/5 (iphone OR MacBook)) | Search for keywords "iphone" or "MacBook" within 5 words of proximity to “Apple”. |
ONEAR | "social media" ONEAR/5 "facebook" | Search for keywords "social media" and "facebook" within 5 words proximity in the order specified (first social media and then facebook). |
author | author: "Justin Blake" | Search for the post with author named: "Justin Blake"; Case Sensitive Operator. |
message | message: ("Gandalf" AND ("Frodo" OR "SAM")) | The message body should contain Gandalf and either of Frodo or Sam. |
title | title: Tesla | Search for mentions that have "Tesla" in their title. |
language | language: en | The language of the mention should be en (English) |
state | state: California | Search for mentions from state: California. |
country | country: IN | Filters the mentions specific to country: IN (India). |
url | url: "https://www.bbc.com/news" | Search for mentions from url: bbc.com/news. |
site | site: cnn.com | Search for mentions from a specific site: cnn.com. |
Wildcards | Searching for me?t will return results with the keywords meat, melt, meet. Searching for melt* will return results with the keywords melt, melts, melting, melted. Limitations:
| single character (?) and multiple characters (*) |
Single line comment | BrandName //query description comment | To provide clarity to a reader, comments can be added within the Story Query using // operator. |
Keyword List (AND) | keyword_list_and("kl_name") | Includes keywords constituting the keyword list separated by AND condition |
Keyword List (OR) | keyword_list_or("kl_name") | Includes keywords constituting the keyword list separated by OR condition |