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

New query option $expect combining $expand and $select

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: New
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: V4.01_OS
    • Fix Version/s: V4.02, V5.0
    • Component/s: URL Conventions
    • Labels:
      None
    • Environment:

      Proposed

    • Proposal:
      Hide

      Introduce a new query option $expect that combines the functionality of $expand and $select in a simplified syntax, inspired by the field list structure used in the context URL. In the simplest form it is just a nested list of fields, with primitive properties as "leafs" and (single- or collection-valued) complex/navigation properties suffixed with parentheses including the field list for their properties, recursively:

      $expect=a,b(c,d,e(f,g),h),i
      

      Query options other than $expect, $expand and $select can be mixed in with the field lists:

      $expect=a,b(c,d,e(f,g,filter=f eq 3),h,top=5,skip=100),i
      
      Show
      Introduce a new query option $expect that combines the functionality of $expand and $select in a simplified syntax, inspired by the field list structure used in the context URL. In the simplest form it is just a nested list of fields, with primitive properties as "leafs" and (single- or collection-valued) complex/navigation properties suffixed with parentheses including the field list for their properties, recursively: $expect=a,b(c,d,e(f,g),h),i Query options other than $expect, $expand and $select can be mixed in with the field lists: $expect=a,b(c,d,e(f,g,filter=f eq 3),h,top=5,skip=100),i

      Description

      Both $expand and $select shape the response, but preserve in query syntax the differentiation between "structural" and "navigation" properties.

      From a pure response shape perspective this differentiation has become less relevant over the last OData increments, supporting paging for all collections, indexing for all ordered collections, and field selection on all structured response parts.

        Attachments

          Activity

            People

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

              Dates

              • Created:
                Updated: