3

I have a LookUp on the Account object to the Location object. When I make a request to the Metadata/SOAP API to get the metadata for the Account Page layout the field is not returned in the XML response body, even though the field is on the page layout.

Every other lookup field is returned via the Metadata/SOAP API. It's only this one that is missing. What could be the reason for this and how can it be resolved?

  • Are you using the same user to both view the record in the UI and to export the layout metadata? – Daniel Ballinger Apr 16 '18 at 22:54
  • Yes, we are using the same user. – Givko Apr 17 '18 at 7:08
  • 1
    Is the Location object part of a managed package by chance? Also, what API version of the Metadata API are you using? – Daniel Ballinger Apr 17 '18 at 10:06
  • The "Location" object is a standard one and the API version is the v42.0(the latest). – Givko Apr 17 '18 at 10:21
  • 1
    I wouldn't call Location one of the core standard API objects as it is part of Field Service Lightning. I suspect this is part of the problem. While it is exposed via the SOAP API, it isn't exposed via the Metadata API. – Daniel Ballinger Apr 17 '18 at 10:33
2

Based on the comments.

The field is a reference to the Field Service Lightning Location sObject. While it is a standard (as in built in) object, it isn't currently exposed to the Metadata API.

As at the time of writing (v42.0), the only Field Service Lightning types exposed to the Metadata API are FieldServiceSettings and Skill.

This seems like a logical explanation for why it isn't appearing in the layout metadata.

  • Hello, I just wanted to ask you if you are sure that the object is exposed via the SOAP API. Because I attempted to get the page layout metadata via the SOAP API, however, the field is still missing. – Givko Apr 18 '18 at 11:14
  • @Givko I suspect the SOAP is still exposing the page layout metadata. So while you can see the overall Location sObject it still won't show in the page layout. I'd suggest raising a support case to get a definitive answer. – Daniel Ballinger Apr 18 '18 at 21:03

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.