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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Unanswered

$Expand does not expand all cases

(0) ShareShare
ReportReport
Posted on by

I have table with contacts in d365, some of them have expandable fields, aka expandable field is not null.

For example, also the problem:
API call

https://yyy.crm4.dynamics.com/api/data/v9.2/contacts?$filter=(yyy_tag_contact_ent/any(s%3A%20s/yyy_name%20eq%20'Agent'))&$expand=yyy_tag_contact_ent($select%3Dyyy_name)

 

returns 11 cases of contacts with expandable yyy_tag_contact_ent field, where yyy_name = 'Agent'

and one of those contacts is contactid = 001, others are contactid =002..011

But when I do API call

https://yyy.crm4.dynamics.com/api/data/v9.2/contacts?$expand=yyy_tag_contact_ent($select%3Dyyy_name)

I get all contacts, also those who has not expandable yyy_tag_contact_ent field, but only contactid=002..011 get yyy_tag_contact_ent field expanded, while contactid = 001 has null /yyy_tag_contact_ent/: []. Yet next field /yyy_tag_contact_ent@odata.nextLink/: /https://yyy.crm4.dynamics.com/api/data/v9.2/contacts(001)/yy_tag_contact_ent?$select=yyy_name/ , gives correct result.

And when I filter only contactid=001
https://yyy.crm4.dynamics.com/api/data/v9.2/contacts?$filter=(contactid%20eq%20001&$expand=yyy_tag_contact_ent($select%3Dyyy_name)
I also get correct result with expandable
yyy_tag_contact_ent field.

Endpoint
https://yyy.crm4.dynamics.com/api/data/v9.2/yyy_tags?$expand=yyy_tag_contact_ent
 has only yyy_name = Agent with expandable yyy_tag_contact_ent field


Where is the problem?

I have the same question (0)

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

News and Announcements

Season of Giving Solutions is Here!

Quick Links

Responsible AI policies

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

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Pallavi Phade Profile Picture

Pallavi Phade 101

#2
Tom_Gioielli Profile Picture

Tom_Gioielli 66 Super User 2025 Season 2

#3
TAHER Mehdi Profile Picture

TAHER Mehdi 58

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans