parent soql query code example
Example: parent soql query
for(University__c u: [select Name,(select Name from colleges__r) from university__c])
{
for(College__c c:u.Colleges__r)
System.debug('University Name:'+u.Name+' College Name:'+c.Name);
}<div class="open_grepper_editor" title="Edit & Save To Grepper"></div>