Skip to content

Support OData key alias #1817

@xuzhg

Description

@xuzhg

OData spec says:

$Key

The value of $Key is an array with one item per key property.

Key properties without a key alias are represented as strings containing the property name.

Key properties with a key alias are represented as objects with one member whose name is the key alias and whose value is a string containing the path to the property.

The second one is not supported in ODL.

Here's an example for Key alias:

"Category": {

  "$Kind": "EntityType",

  "$Key": [

    {

      "EntityInfoID": "Info/ID"

    }

  ],

  "Info": {

    "$Type": "self.EntityInfo"

  },

  "Name": {

    "$Nullable": true

  }

},

"EntityInfo": {

  "$Kind": "ComplexType",

  "ID": {

    "$Type": "Edm.Int32"

  },

  "Created": {

    "$Type": "Edm.DateTimeOffset",

    "$Precision": 0

  }

}

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions