We are planning to use SOSL to search for a phone number on all phone fields in the Account object, and in our custom Address object. I know that when we use SOQL, performance can be improved by using custom indexes, but will we see the same performance improvement if we put a custom index on all the phone fields?

1 Answer 1


I'm not sure if you would see a performance improvement by having a custom phone index on all phone fields since there's a point of diminishing returns on the number of indexes created and the performance gains realized. But in any case, I'm pretty sure that Salesforce will push back on your request to create all of these phone indexes just for the sake of a performance boost while using SOSL.

In my experience, getting a custom index built is something that requires solid justification for doing so, such as a non-selective query error. You can give it a shot, but I think you'll run into resistance if you request additional indexes just to see some potential performance gains. But if you do request this and are able to get the indexes created just for the sake of performance, please let us know how you did it.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .