4
我使用WebAPI 2.2與OData V4。
我可以使用$filter=RelatedObj/PropertyName eq 'Some Value'
根據相關的對象屬性值來過濾實體列表。
然而,當我嘗試使用與$select
相同的語法:
$select=Id,Name,RelatedObj/PropertyName
結果異常:
"message": "The query specified in the URI is not valid. Found a path with multiple navigation properties or a bad complex property path in a select clause. Please reword your query such that each level of select or expand only contains either TypeSegments or Properties.",
"innererror": {
"message": "Found a path with multiple navigation properties or a bad complex property path in a select clause. Please reword your query such that each level of select or expand only contains either TypeSegments or Properties.",
"type": "Microsoft.OData.Core.ODataException",
這個問題能解決?
做我試了一下力工作 –