You need to sign in to do that
Don't have an account?

Error: Compile Error: unexpected token: RETURNING at line 3 column 34
Code:
public class ContactAndLeadSearch{
public static List<List<SObject>> searchContactsAndLeads(String name){
return [FIND :name IN Name RETURNING Leads(Name),Contact(FirstName,LastName)];
}
}
I am just trying to return Lead and Contact object where name contains the string passed to this method.
public class ContactAndLeadSearch{
public static List<List<SObject>> searchContactsAndLeads(String name){
return [FIND :name IN Name RETURNING Leads(Name),Contact(FirstName,LastName)];
}
}
I am just trying to return Lead and Contact object where name contains the string passed to this method.
All Answers
This worked for me.