Skip to main content

In Salesforce and looping through the collection ( ie without SOQL for loops )? Please share code example 

6 answers
  1. Oct 27, 2022, 7:50 AM

    Hi @Debaranjan Ghosh

     

    You can directly assign to a list variable 

    List<Account> accounts = [SELECT Id FROM Account];
0/9000