function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Sunil AroraSunil Arora 

SOSL in APEX

Can we use SOSL in APEX?
SuperfellSuperfell
http://www.salesforce.com/us/developer/docs/apexcode/index_CSH.htm#langCon_apex_SOQL.htm
MDXHikerMDXHiker

Does this require any permissions to be set ?

I try a search query in API and it returns the desired result but returns no records in Apex.

 

String searchQuery='FIND \'te*\' RETURNING Opportunity(Amount, Description, Name)';
List<List<SObject>> searchList=search.query(searchQuery);
System.debug('searchList size is...'+searchList.size());
 

 Thanks

cpetersoncpeterson

I have the same problem, and posted another thread about it without a reply: 

http://community.salesforce.com/sforce/board/message?board.id=apex&message.id=20640

Message Edited by cpeterson on 10-01-2009 12:40 PM