[ 
https://issues.apache.org/jira/browse/OLINGO-1143?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16207685#comment-16207685
 ] 

Stefan Hasse commented on OLINGO-1143:
--------------------------------------

I could reproduce this issue, but only in combination with select...
{{/Customers?$expand=addresses/country}} works like expected and the result has 
country within addresses expanded
{{/Customers?$select=name&$expand=addresses/country}} I expected to get name 
and addresses, but as addresses is a complex type that is not selected I get 
name only

Based on the standard [5.1.3 System Query Option 
$select|http://docs.oasis-open.org/odata/odata/v4.0/errata03/os/complete/part2-url-conventions/odata-v4.0-errata03-os-part2-url-conventions-complete.html#_Toc453752360]
 {quote}selectProperty = primitiveProperty 
               / primitiveColProperty
               / *navigationProperty*
               / selectPath [ "/" selectProperty ]{quote} a workaround could be 
{{/Customers?$select=name,addresses/country&$expand=addresses/country}}


> Expand of a navigation property of a complex type does not render
> -----------------------------------------------------------------
>
>                 Key: OLINGO-1143
>                 URL: https://issues.apache.org/jira/browse/OLINGO-1143
>             Project: Olingo
>          Issue Type: Bug
>          Components: odata4-server
>    Affects Versions: (Java) V4 4.3.0
>            Reporter: Simon Ammer
>            Priority: Blocker
>
> Here is an example URL provided in the [OData URL 
> Conventions|https://docs.oasis-open.org/odata/odata/v4.0/odata-v4.0-part2-url-conventions.pdf#page=37]
>  that could be used to reproduce the issue:
> [http://host/service/Customers?$expand=Addresses/Country]
> The ODataJsonSerializer only processes _Addresses_ but ignores _Country_. 
> Therefore only the _Addresses_ are shown in the response.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to