function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
ravi teja 81ravi teja 81 

query to retrive related data

hi 

i have job application custom object,in which i have two lookups (position and candidate) iwant to retrieve candidate email and name according to position name. is it possible if please tell me how to query.

Himanshu ParasharHimanshu Parashar
Hi Ravi,

You can use following query
 
SELECT Email__c,First_Name__c,Id,Last_Name__c FROM Candidate__c where id in  (select Job_Candidate__c from Job_Application__c where Job_Position__r.name='SFDC')
Let me know if it makes sense.

Thanks,
Himanshu
Salesforce Certified Developer | Administrator | Service Cloud Consultant

P.S. If my answer helps you to solve your problem please mark it as best answer. It will help other to find best answer.