I have two tables in a database Items and Details but when I do a
Item item = _inventoryContext.Items
.Expand("Details")
.Where(i => i.Id == theAuction.InventoryReference)
.First();
to get a list of Items with the details populated, the details are never populated.
What I’ve tried:
- looked at the database, the details are definately populated
- used the browser to see I can get the Details from the url – I can
- updated the service reference
Nothing has helped so far.
Thanks,
Sachin
I fixed this by setting the MergeOption on the context. I set the value to MergeOption.OverwriteChanges. Since I’m not going to change the values locally while I’m using it it’s ok for me to do that. The reason why it seems not to have set the values is perhaps because Details was not null to begin with and therefore it’s value was ‘set’.