Allow usage of $apply as "Expand Option" in $expand

    • Type: Improvement
    • Resolution: Fixed
    • Priority: Major
    • V4.0_CSD03
    • Affects Version/s: V4.0_CS01
    • Component/s: Data Aggregation
    • None
    • Environment:

      [Applied]

      We haven't specified the usage of $apply as "Expand Option" in $expand.
      There are good use cases for $apply as an option of $expand (and it combines very well):

      GET Products?$expand=Sales($apply=aggregate(Amount with sum as Total))

      Returns all products, and the Sales navigation property value is a one-element array with the Total
      Means: per Product in top-level result inline result of

      GET Product(<key>)/Sales?$apply=aggregate(Amount with sum as Total)

      This is equivalent to the clumsier

      GET Products?$apply=groupby((<key properties of Product>,<all non-key structural properties of Product>),aggregate(Sales/(Amount with sum as Total))

            Assignee:
            handl
            Reporter:
            martinzurmuehl
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: