Created
July 10, 2017 10:07
-
-
Save 101dvlp/cc91e9f3ed8228f8918f42b435dee83b to your computer and use it in GitHub Desktop.
SOSL Sample
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
List<List<SObject>> searchList = [FIND '*test*' IN NAME FIELDS RETURNING Account(Id, Name), Contact]; | |
Account[] ac = ((List<Account>)searchList[0]); | |
Contact[] co = ((List<Contact>)searchList[1]); | |
System.debug(ac[0].Name); | |
System.debug(co[0].Name); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment