- Free Edition General Troubleshooting Steps
- Search Interface Does Not Return the Expected Results in the Coveo for Salesforce Pro or Enterprise Edition
- Enabling the Interface Editor in Your Salesforce Organization
- Coveo Search Page Fails to Load After Upgrade
- Insight Panel Refuses to Display
- Unable to Install the Coveo Lightning Component for Community Cloud
- Something Went Wrong Message When Selecting a Value in the Created By Facet
- Error When Adding or Accessing Coveo Components in a Lightning Community
- Error While Performing JWT Flow for the Requested User When Using Customer Community or Portal User With the Coveo for Salesforce Free Edition
- Filtering on NetworkScope Returns UnsupportedQueryExpressionException
- Getting a MALFORMED\_SEARCH Error When Selecting a Tab With the Coveo for Salesforce Free Edition
- Cannot See Values When Using an Existing Field in a Facet
- Unknown Page for the Current Site Configuration Error With Coveo Lightning Components
- Coveo Object Unavailable in Lightning Component
- The Feature is Not Activated for Your Organization
- The Search Token is Invalid in the Health Check Page
- An Unexpected Error Has Occurred In the Coveo Health Check Page After Deleting Coveo Cloud Organization
- Uncaught-DOMException-Failed-to-read-the-'responseText'-property-from-'XMLHttpRequest' Error Message When Using a Component
- Infinite Loading When Trying to Preview a Document in a Quick View
- Access Token Update Required
Search Interface Does Not Return the Expected Results in the Coveo for Salesforce Pro or Enterprise Edition
For the Coveo for Salesforce Free edition equivalent of this page, see Search Interface Does Not Return the Expected Results in the Coveo for Salesforce Free Edition.
When querying your Coveo components, you get to the search page, and you either do not have access to results, or do not have all the results you expected to see.
There is also no error message displayed.
There are two possible causes for this:
- The user you are using to query the component does not have access to those items. This is the expected behavior.
- One of the filters for your search page is either too restrictive or invalid.
To resolve this issue, you need to review the full query sent to the index, and perform the same query in the Coveo Cloud administration console.
Step 1 - Ensure That the Item You Want Is Available in the Index
- Access the Administration Console of your Coveo Cloud organization (see Logging in to Coveo Cloud V2).
- Under Content, select Content Browser.
- To ensure that you can see all available items, select the Preferences button () at the end of the search bar, and check the View all content box.
- Search for the item you want to see in your search results.
- If you can find it, you can continue to Step 2.
- If you cannot find it, your index does not contain the item you want to find. You thus need to review the way your sources are configured, and then rebuild them (see Adding and Managing Sources).
Step 2 - Get Your Search Page Full Query
- Access your search interface, and open your browser console in the Network tab.
- Perform a search on your page, which you would expect would return your desired results.
- You should see two XHR requests to
platform.cloud.coveo.com, usually named
v2/. Select the last one.
- In the Headers of the request, scroll to Form Data.
The q, aq, cq, dq, and lq elements can all change which items should and should not be displayed in your search interface.
Copy the value of all of those elements into the text editor of your choice.
You will most likely not be able to find all of the previously listed elements in the Form Data. This is because when a value is empty, it is not sent.
- Back in the XHR request, still in the Headers section, scroll to the Request Headers section.
Under Authorization, you should see an authorization token that looks like this:
Copy the full token, which starts with
- Access JWT.io, and under Encoded, paste your token. You should see the decoded token under Decoded.
In the Decoded section, if you have a
filterelement, copy its value and paste it in your text editor.
Remember to change all instances of
", as the quotation marks will not need to be escaped.
- You may want to note the
userIdsused in your search interface, as they might become useful later.
In your text editor, add parentheses around the value of each element.
This will serve as your base query.
In your search page, you find that your form data sends the following query:
q: mobile aq: @objecttype==(Case, Knowledge) cq: @language=="English" NOT @filetype=="Image"
Your token also has the following filter in its token:
@source==\"My Salesforce Source\"
Your base query would look like this:
(mobile) (@objecttype==(Case, Knowledge)) (@language=="English" NOT @filetype=="Image") (@source=="My Salesforce Source")
Step 3 - Test Your Query in the Content Browser
Access your Coveo Cloud Content Browser again, as in Step 1 (see Step 1 - Ensure That the Item You Want Is Available in the Index).
- In the search bar of the Content Browser, enter the base query you got from Step 2 (see Step 2 - Get Your Search Page Full Query).
- Perform the search with your base query.
- If you can find your item with the base query:
- You made a mistake copying your base query. Ensure that you copied all the filters from your search page, and ensure it follows the Coveo Cloud query syntax (see Coveo Cloud Query Syntax Reference).
- The user of your search page does not have access to your item. You may need to verify that the users you got from the
userIdselement in your token has access to the item inside Salesforce, or whichever source your item comes from.
- If you cannot find your item with the base query, you may continue this procedure, as it is the expected outcome.
- If you can find your item with the base query:
- Granularly remove parts of your query, until you have identified which part of the query is preventing your item from being returned.
Once you have identified which part of the query is preventing the item from being returned, identify why it is not returned.
Reasons might include: