Use this Explore recipe to display tickets with a specific word or string in the subject field.
What you'll need
Skill level: Intermediate
Time required: 10 mins
- Zendesk Explore Professional or Enterprise
- Editor or Admin permissions (see Giving agents access to Explore)
- Ticket data in Zendesk Support
Creating the query
In this procedure, you'll create a standard calculated attribute that returns "Has this word" if the ticket subject line contains the search string "support". If the subject doesn't contain the string then "Does not have this word" is returned. You'll then use this attribute to create your report.
To create the query
- In Explore, click the query () icon.
- In the Queries library, click New query.
- On the Choose a dataset page, click Support > Tickets > Support: Tickets [default], then click New query.
- In the Calculations menu (), click Standard calculated attribute.
- On the Standard calculated attribute page, give your new metric a name like “Contains”.
In the Formula field, enter or paste the following formula, replacing the word "support" with the word or phrase you want to search for (in lower case):
IF (CONTAINS(LOWERCASE([Ticket subject]),"support"))Enter the search term in lower case only. However, the search results are not case-sensitive. In the example above, “Support”, “SUPPORT”, and “sUpPoRt” would all be found.
THEN "Has this word"
ELSE "Does not have this word"
Tip: If you're working in a language other than English, read this article to help you enter Explore formulas in your language.
- When you are finished, click Save.
- In the Metrics panel, click Add.
- From the list of metrics, choose Tickets > Tickets, then click Apply.
- In the Rows panel, click Add.
From the list of attributes, choose Calculated attributes > Contains, Tickets >Ticket ID and Tickets > Ticket Subject, then click Apply. The query will match the following:
And you’re finished! The screenshot below shows an example of the finished result with your tickets grouped by whether or not their subject contains the word or phrase you specified.