0

I want to get the name of the contact in the lookup field npe01__One2OneContact__c on Account object.

How do I get the contact name using a SOQL query?

  • 1
    Since its relationship field shouldn't it be npe01__One2OneContact__r.Name? Have you tried this? – d_k May 7 '18 at 14:26
0

There's nothing NPSP-specific about querying from the Household to the Primary Contact as such - it's just a normal SOQL relationship query, using the

Lookup_Field__r.Child_Field__c

syntax, which here would be

npe01__One2OneContact__r.Name

The only unique feature of the NPSP that comes into play here is the account model. Because you're working in an org that has Primary Contacts, you should be using NPSP 3.0+ with the Household Account model, which is where that feature is available.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.