I need to join Account (type = person account) --> Junction Object --> Account (type = business account)
We have person accounts enabled on our org. I can easily write what I need in SQL, but writing it in SOQL has proven difficult. Can you assist in writing a SOQL statement that pulls fields from person/customer account and business account?
SELECT * FROM Account as customerAccount JOIN Junction__c ON Junction__c.customerID__c = customerAccount.ID JOIN Account as businessAccount ON businessAccount.ID = Junction__c.businessID__c