List<Account> accList = new List<Account>();
accList = [select id, name from Account where name like '%a%'];
for(Account acc : accList){
system.debug('======Account' Name======' + acc.name);
}
List<Account> accList = new List<Account>();
accList = [select id, name from Account where name like '%a%'];
for(Account acc : accList){
system.debug('======Account' Name======' + acc.name);
}
FYI. https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_methods_system_list.htm?search_text=LIST
All Answers
You could traverse your return list.
Thanks.
Thanks for your quick response.Do you have any sample code.
Thanks,
FYI. https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_methods_system_list.htm?search_text=LIST