Uploaded image for project: 'OASIS Open Data Protocol (OData) TC'
  1. OASIS Open Data Protocol (OData) TC
  2. ODATA-144

"Scoping" syntax for $aggregate

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: V4.0_WD01
    • Fix Version/s: V4.0_WD01
    • Component/s: Data Aggregation
    • Labels:
      None
    • Environment:

      [Proposed]

    • Proposal:
      Hide

      We will adopt grouping of properties for $aggregate as the only way to specify multiple or aliased sub properties of a navigation.

      The parens are required only if you have more than one property or in the case that you use an as.

      legal:
      $aggregate=Items/Price
      $aggregate=Items/(Price)
      $aggregate=Items/(Price as AggregatePrice)
      $aggregate=Items/(Price,Amount)

      not legal:
      $aggregate=Items/Price as AggregatePrice
      $aggregate=Items/Price,Items/Amount

      Accepted: https://www.oasis-open.org/apps/org/workgroup/odata/download.php/47432/latest/odata-meeting-15_on-20121108_9-F2F-minutes.html

      Show
      We will adopt grouping of properties for $aggregate as the only way to specify multiple or aliased sub properties of a navigation. The parens are required only if you have more than one property or in the case that you use an as. legal: $aggregate=Items/Price $aggregate=Items/(Price) $aggregate=Items/(Price as AggregatePrice) $aggregate=Items/(Price,Amount) not legal: $aggregate=Items/Price as AggregatePrice $aggregate=Items/Price,Items/Amount Accepted: https://www.oasis-open.org/apps/org/workgroup/odata/download.php/47432/latest/odata-meeting-15_on-20121108_9-F2F-minutes.html
    • Resolution:
      Show
      Accepted: https://www.oasis-open.org/committees/download.php/49055/odata-meeting-35_on-20130502-minutes.html#odata-144

      Description

      The current syntax for $select requires to qualify each single included property with its navigation path. We propose an alternative/additional syntax that allows grouping by path:
      $select=Items/(Price,Currency,Quantity,Unit)

      The same notation would be useful for the data aggregation extension:
      $aggregate=Sales/(sum(Amount),average(Amount) as AvgAmt)

        Attachments

          Activity

            People

            • Assignee:
              handl Ralf Handl
              Reporter:
              handl Ralf Handl
            • Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: