I am using SOSL to search records in Salesforce. According to document http://www.salesforce.com/us/developer/docs/soql_sosl/Content/sforce_api_calls_sosl_limit.htm, It should return 2000 records but it's only returning 500 records.
SOSL query: FIND {Not Given} RETURNING " + "Lead(Id, Phone, FirstName, LastName)
I verified by running following SOQL query that more than 500 records exist for this criteria.
Select Id, Name from Lead where LastName like '%Not Given%'
One interesting thing to note is - this 500 limit seems to be per Object, not per query. Because on running following query
FIND {Not Given} RETURNING " + "Lead(Id, Phone, FirstName, LastName), Account(Id)
It returns 500 leads and 13 Accounts.
Any suggestions where is this limit coming from?
EDIT: I tried to use Developer Console in Salesforce website and run SOSL query directly in it. It is also returning only 500 records. So Seems like this limit is like some organization wide limit. I asked our Salesforce admin but he couldn't find out.
I am using enterprise wsdl version no 28.0. Though using WSC-23.0 to generate classes from wsdl. Could this be an issue?