2

I am trying to find out how to access each component of the mailing address on our person account object. The mailing address is on the contact but it's being display through the account. I'm having trouble finding the path for let's say the city field. Ie. Account.PersonMailingCity isn't working, nor is Contact.PersonMailingCity and not Contact.PersonMailingAddress.City either, etc.

3

You can retrieve the values on MailingAddress for Person Accounts as for other compound fields.

As an example using REST API, if I have the following request to retrieve values for one of my Person Accounts:

/services/data/v43.0/sobjects/Account/001xxxxxx?fields=Id,Name,PersonMailingStreet,PersonMailingCity

I get the response:

{
    "attributes": {
        "type": "Account",
        "url": "/services/data/v43.0/sobjects/Account/001xxxxx"
    },
    "Id": "001xxxxxx",
    "Name": "Jayant Das",
    "PersonMailingStreet": "1000 My Street",
    "PersonMailingCity": "My City"
}

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.