You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've looked over documentation and bugs, but I don't see any example of how to do this.
I am looking to generate the following OData query: /orders?$expand=items($expand=customer)?
With the Expand method that takes a string, it is simple: orderQuery.Expand("items($expand=customer)");
How is this accomplished with the overload that takes an expression? orderQuery.Expand(o => o.Items); is the closest I can get. How do I then expand the Customer navigation property on each of the items?
Here's what I have tried that does NOT work. orderQuery.Expand(o => o.Items.First().Customer); orderQuery.Expand(o => ((DataServiceQuery<Item>)o.Items).Expand(i => i.Customer)); orderQuery.Expand(o => (o.Items as DataServiceQuery<Item>).Expand(i => i.Customer));
Any help would be appreciated.
The text was updated successfully, but these errors were encountered:
I've looked over documentation and bugs, but I don't see any example of how to do this.
I am looking to generate the following OData query:
/orders?$expand=items($expand=customer)
?With the
Expand
method that takes a string, it is simple:orderQuery.Expand("items($expand=customer)");
How is this accomplished with the overload that takes an expression?
orderQuery.Expand(o => o.Items);
is the closest I can get. How do I then expand theCustomer
navigation property on each of the items?Here's what I have tried that does NOT work.
orderQuery.Expand(o => o.Items.First().Customer);
orderQuery.Expand(o => ((DataServiceQuery<Item>)o.Items).Expand(i => i.Customer));
orderQuery.Expand(o => (o.Items as DataServiceQuery<Item>).Expand(i => i.Customer));
Any help would be appreciated.
The text was updated successfully, but these errors were encountered: