For collection-valued properties the value of $Type is the qualified name of the property’s item type, and the member $Collection MUST be present with the literal value true. Absence of the $Type member the type is Edm.String. This member SHOULD be omitted for string properties to reduce document size. Example : property Units that can have zero or more strings as its value "Units": { "$Collection": true } Type Facets Facets modify or constrain the acceptable values of a property. For single-valued properties the facets to the value of the property. For collection-valued properties the facets apply to the items in the collection. Nullable A Boolean value specifying whether a value is required for the property. $Nullable The value of $Nullable is one of the Boolean literals true or false. Absence of the member means false. MaxLength A positive integer value specifying the maximum length of a binary, stream or string value. For binary or stream values this is the octet length of the binary data, for string values it is the character length. If no maximum length is specified, clients SHOULD expect arbitrary length. $MaxLength The value of $MaxLength is a positive integer. Note: [] defines a symbolic value max that is only allowed in OData 4.0 responses. This symbolic value is not allowed in CDSL JSON documents at all. Services MAY instead specify the concrete maximum length supported for the type by the service, or omit the member entirely. Precision For a decimal the maximum number of significant decimal digits of the property’s value; it MUST be a positive integer. For a temporal (datetime-with-timezone-offset, duration, or time-of-day): the number of decimal places allowed in the seconds portion of the value; it MUST be a non-negative integer between zero and twelve. Note: service authors SHOULD be aware that some clients are unable to support a precision greater than 28 for decimal properties and 7 for temporal properties. Client developers MUST be aware of the potential for data loss when round-tripping values of greater precision. Updating via PATCH and exclusively specifying modified properties will reduce the risk for unintended data loss. $Precision The value of $Precision is a number. Absence of $Precision means arbitrary precision. Example : facet applied to the DateTimeOffset type Precision
For collection-valued properties the value of $Type is the qualified name of the property’s item type, and the member $Collection MUST be present with the literal value true. Absence of the $Type member the type is Edm.String. This member SHOULD be omitted for string properties to reduce document size. Example : property Units that can have zero or more strings as its value "Units": { "$Collection": true } Type Facets Facets modify or constrain the acceptable values of a property. For single-valued properties the facets to the value of the property. For collection-valued properties the facets apply to the items in the collection. Nullable A Boolean value specifying whether a value is required for the property. $Nullable The value of $Nullable is one of the Boolean literals true or false. Absence of the member means false. MaxLength A positive integer value specifying the maximum length of a binary, stream or string value. For binary or stream values this is the octet length of the binary data, for string values it is the character length. If no maximum length is specified, clients SHOULD expect arbitrary length. $MaxLength The value of $MaxLength is a positive integer. Note: [] defines a symbolic value max that is only allowed in OData 4.0 responses. This symbolic value is not allowed in CDSL JSON documents at all. Services MAY instead specify the concrete maximum length supported for the type by the service, or omit the member entirely. Precision For a decimal the maximum number of significant decimal digits of the property’s value; it MUST be a positive integer. For a temporal (datetime-with-timezone-offset, duration, or time-of-day): the number of decimal places allowed in the seconds portion of the value; it MUST be a non-negative integer between zero and twelve. Note: service authors SHOULD be aware that some clients are unable to support a precision greater than 28 for decimal properties and 7 for temporal properties. Client developers MUST be aware of the potential for data loss when round-tripping values of greater precision. Updating via PATCH and exclusively specifying modified properties will reduce the risk for unintended data loss. $Precision The value of $Precision is a number. Absence of $Precision means arbitrary precision. Example : Precision facet applied to the DateTimeOffset type