- Salesforce Development Posts by Matt Lacey

Entity Type XYZ Does Not Support Search

Posted: 2022-02-06

At some stage in your Salesforce development career you might be greeted by an error in response to a query, which states "Entity Type Object__c does not support search", and frankly it's quite rare to see, but sometimes very easily fixed. Some objects are never searchable, usually those with very specific uses in Salesforce such as Knowledgeableuser, and in that case you're SOL. For the scenarios where there is an easy fix, it comes down to a checkbox you've probably seen a thousand times and paid attention to exactly zero times:

Image showing the bottom part of the object details section for a custom Object, with a checkbox titled 'Allow Search'

Find the object in question in Object Manager, hit the Edit button on the details screen and check "Allow Search" under Search Status. If you're anything like me you'll likely have never paid attention to this box when creating an object during development, and naturally it defaults to enabled. If it's disabled, you'll see the error message above when trying to query that object.