OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

odata message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: [OASIS Issue Tracker] (ODATA-977) Allow POST with $apply to invoke an action to an aggregated result


     [ https://issues.oasis-open.org/browse/ODATA-977?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ralf Handl updated ODATA-977:
-----------------------------

        Fix Version/s:     (was: V4.01_WD01)
    Affects Version/s: V4.0_CS02
                           (was: V4.0_CS01)
                           (was: V4.0_ERRATA02)
          Environment: Proposed  (was: Set Operations)
          Description: 
Currently it is not possible to aggregate data  and then directly apply an action to the aggregation result. 

An interesting special case is to filter an entity set and then apply an action to the set of entities that passes the filter, e.g. discount all products that have been on the shelf for more than three months.

filter an entity set and then apply an action to the entities passing the filter, e.g. discount all products that have been on the shelf for more than three months.

  was:Currently it is not possible to filter an entity set and then apply an action to the entities passing the filter, e.g. discount all products that have been on the shelf for more than three months.

             Proposal: 
Add to chapter 3:

Service-defined bound actions that take an entity set as their binding parameter MAY be used as the last set transformation within $apply if the type of the binding parameter matches the type of the result set of the preceding transformation. In this case the request MUST be a POST request.

Example:
Discount all products that meet a filter condition

  POST Products?$apply=filter(ShelfLife gt duration'P90D')/Special.Discount(Percent=15)

  was:
Either add a path segment that takes a boolean expression, optionally deferred to a parameter alias, or allow POST in combination with $apply

POST Products/$filter(Age gt 3)/Special.Discount
POST Products/$filter(@f)/Special.Discount?@f=Age  gt 3

POST Products?$apply=filter(Age gt 3)/Special.Discount

Consider adding path equivalents of other query options:

POST /Orders/$filter(@f)/$top(5)/Ship?@f=Details/ShippingDate lt now()


> Allow POST with $apply to invoke an action to an aggregated result
> ------------------------------------------------------------------
>
>                 Key: ODATA-977
>                 URL: https://issues.oasis-open.org/browse/ODATA-977
>             Project: OASIS Open Data Protocol (OData) TC
>          Issue Type: Improvement
>          Components: OData Extension for Data Aggregation
>    Affects Versions: V4.0_CS02
>         Environment: Proposed
>            Reporter: Ralf Handl
>              Labels: Extension
>             Fix For: V4.0_CSD04
>
>
> Currently it is not possible to aggregate data  and then directly apply an action to the aggregation result. 
> An interesting special case is to filter an entity set and then apply an action to the set of entities that passes the filter, e.g. discount all products that have been on the shelf for more than three months.
> filter an entity set and then apply an action to the entities passing the filter, e.g. discount all products that have been on the shelf for more than three months.



--
This message was sent by Atlassian JIRA
(v6.2.2#6258)


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]