My Dynamics 365 implementation has a number of custom solutions which act to link up the data various entities. When I query D365 using an HTTP request, I can use $expand to reference custom navigation properties associated with an Entity to retrieve all the data I need in one query string.
However the 'Expand Query' input field in the 'List Records' action doesn't seem to work with these custom navigation properties (in fact, it seems to fail silently, with the Flow running successfully but no data returned from the expand query). This is a problem for me as sometimes these are the only way to connect the data in two different records, which means I can't use Flow in these cases. Please could you roll out support for this?
Hi @ozer85 ，
Could you please share a screenshot of the configuration of your flow?
I have made a test on my side , hope the link below could be your reference:
Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks very much for your response. As requested, here is a screenshot of the relevant bit of my Flow (everything works to this point and I get the expected response, but without the expand query data):
For context, below is the relevant bit of the dynamics metadata showing the navigation property.
I know that it works correctly because the following HTTP request works fine (taken from a Python script I wrote with URI encoding, but should work in any language):
https://[MyDynamicsBaseURL]/api/data/v9.1/svrsys_insights?$filter=svrsys_name%20eq%20%27' + title_variable +'%27%20and%20_svrsys_publishingstate_value%20eq%20%2789bfc7ac-8937-4c77-a83d-455082770200%27&$select=svrsys_publisheddate&$expand=svrsys_svrsys_insight_tcrmb_programme($select=tcrmb_programmeid)
However while the Flow executes succesfully and returns data from the 'List Records' request (see below), it doesn't include the expand query data in the returned JSON object. Perhaps there is an issue with using a filter query and an expand query in the same request?