web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Service | Customer Service, Contact Center, Fie...
Suggested answer

How do we identify if the lookup field is multiple reference field?

(0) ShareShare
ReportReport
Posted on by

Hi Team ,

 I want to know any Rest API to identify if the lookup field is multiple reference field ?

I used this below API to get field attributes :  /api/data/v9.1/EntityDefinitions(LogicalName%20=%20'phonecall')/Attributes , i didn't identify the field is multiple reference from the API response.

Can anyone help to find out multiple reference fields for the form like Phonecall ( To field ) ?

test.png

I have the same question (0)
  • Suggested answer
    LeoAlt Profile Picture
    16,331 Moderator on at
    RE: How do we identify if the lookup field is multiple reference field?

    Hi partner,

    Actually, the From and To field are not lookup fields, they are "Party List" fields.

    https://docs.microsoft.com/en-us/dynamics365/customerengagement/on-premises/developer/activityparty-entity

    pastedimage1591839628228v1.png

    And we could use REST API to retrieve attribute type in Metedata.

    For example, I want to get all Party List fields in Phone call entity, I will use this request.

    GET [Organization URI]/api/data/v9.0/EntityDefinitions(LogicalName='phonecall')?$select=LogicalName&$expand=Attributes($select=LogicalName;$filter=AttributeType eq Microsoft.Dynamics.CRM.AttributeTypeCode'PartyList')

    pastedimage1591839776932v2.png

    https://docs.microsoft.com/en-us/powerapps/developer/common-data-service/webapi/query-metadata-web-api#querying-entitymetadata-attributes

    pastedimage1591839803530v3.png

    https://docs.microsoft.com/en-us/dynamics365/customer-engagement/web-api/attributetypecode?view=dynamics-ce-odata-9

    And here is the result.

    pastedimage1591839877306v4.png

    And if you want to check a special field if it is party List field, you could use this request.

    GET [Organization URI]/api/data/v9.0/EntityDefinitions(LogicalName='account')/Attributes(5967e7cc-afbb-4c10-bf7e-e7ef430c52be)/Microsoft.Dynamics.CRM.PartyListAttributeMetadata?$select=LogicalName&$expand=OptionSet 
    pastedimage1591839972618v5.png

    https://docs.microsoft.com/en-us/powerapps/developer/common-data-service/webapi/query-metadata-web-api#retrieving-attributes

    Best Regards,

    Leo

  • Community Member Profile Picture
    on at
    RE: How do we identify if the lookup field is multiple reference field?

    Thanks for your reply. Is there any multiple reference fields in MSDynamics? If yes , how do we identify?

  • LeoAlt Profile Picture
    16,331 Moderator on at
    RE: How do we identify if the lookup field is multiple reference field?

    Hi partner,

    What does "multiple reference fields" mean? If you mean the field like "Call To" which could store multiple records in lookup filed, it is actually Party List field as I mentioned before.

    And if you want to identify them, the default party list fields are list in the link I provided in my last answer.

    And if you want to identify them by code, you could also use the web api to retrieve the attribute type as I mentioned in my last answer also.

    If my understanding is not correct, please feel free to let me know.

    Regards,

    Leo

  • Community Member Profile Picture
    on at
    RE: How do we identify if the lookup field is multiple reference field?

    Thanks . In this document - Partlist lookup allow multiple reference to multiple entities. docs.microsoft.com/.../types-of-fields

    But Call "from" allow single entity only and "to" allow multiple entities. how do we differentiate it from api response ?

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > Service | Customer Service, Contact Center, Field Service, Guides

#1
MVP-Daniyal Khaleel Profile Picture

MVP-Daniyal Khaleel 60

#2
Tom_Gioielli Profile Picture

Tom_Gioielli 16 Super User 2025 Season 2

#2
CU29080825-0 Profile Picture

CU29080825-0 16

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans