You need to sign in to do that
Don't have an account?
SOSL in documents
Hi,
I read some where that SOSL will allow you to search on documents and to use a * and ? for search terms. What I am not sure is what type of documents are supported and how does it works on a combination of * and ?. Example, the following query:
for(Document doc:(List<Document>)[FIND '*dfgdfg*' IN ALL FIELDS RETURNING Document(id)][0]){ }
will return all the documents on my org (including PDF, word, txt), which BTW does not contain a string 'dfgdfg' or any other string that contains 'dfgdfg'.
In the other hand, if I remove the * (wild card) symbol it returns nothing, which is what I expected. Also I get a correct answer if I search any term without the * (wild card) symbol.
Is this a bug or just should not be used in this way?
Here are some documents that may help you
http://www.salesforce.com/us/developer/docs/api/Content/sforce_api_calls_sosl.htm
http://www.salesforce.com/us/developer/docs/apexcode/Content/langCon_apex_SOQL.htm
Ignacio.