Christian Holzer created OLINGO-596:
---------------------------------------

             Summary: Client URI-Builder uses commas instead of semicolons to 
separate system query options in expand options
                 Key: OLINGO-596
                 URL: https://issues.apache.org/jira/browse/OLINGO-596
             Project: Olingo
          Issue Type: Bug
          Components: odata4-client
    Affects Versions: (Java) V4 4.0.0-beta-03
            Reporter: Christian Holzer
            Priority: Minor


Client URI-Builder uses commas instead of semicolons to separate system query 
options in expand options.

For example:
{code:java}
Map<QueryOption, Object> options = new HashMap<QueryOption, Object>();
    options.put(QueryOption.FILTER, "Name eq 'Dave'");
    options.put(QueryOption.ORDERBY, "Age desc");
    ODataClientFactory.getClient().newURIBuilder(SERVICE_URI)
        .appendEntitySetSegment("MyEntitySet")
        .expandWithOptions("NavProperty", options).build();

{code:java}
The URI looks like “/MyEntitySet?$expand=NavProperty($filter=Name eq 
Dave,$orderby=Age desc)

OData Version 4.0 Part 2: URL Conventions Plus Errata 02 chapter 5.1.2 says 
{quote}
Query options can be applied to the expanded navigation property by appending a 
semicolon-separated list of query options, enclosed in parentheses, to the 
navigation property name. Allowed system query options are $filter, $select, 
$orderby, $skip, $top,$count, $search, and $expand.”
{quote}

So the URI should look like “/MyEntitySet?$expand=NavProperty($filter=Name eq 
Dave;$orderby=Age desc)

Kind regards
Christian




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to