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

Announcements

No record found.

News and Announcements icon
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

    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

    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

    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

    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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the April Top 10 Community Leaders

These are the community rock stars!

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

#1
FSRon Profile Picture

FSRon 75

#2
James White Profile Picture

James White 21

#3
AT-28040446-0 Profile Picture

AT-28040446-0 20

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans