-
Notifications
You must be signed in to change notification settings - Fork 3
Closed
Description
To be able to omit a nullable property, it must be given a DefaultValue of null, because the client SHOULD NOT assume a DefaultValue otherwise (OData-CSDL, section 7.2.7).
In CSDL JSON, this can be expressed as
{"PropertyName": {"$Nullable": true, "$DefaultValue": null}}
But in CSDL XML, it cannot be expressed:
<Property Name="PropertyName" Type="Edm.String" Nullable="true"
DefaultValue="null" />
would mean the string "null" as DefaultValue.
Questions:
- Can the server assume a DefaultValue if none is specified?
- OData-Protocol, section 8.2.8.6 instructs the client to interpret a missing property without DefaultValue as having null value. Does the "SHOULD NOT" rule above apply only to the case without
omit-values
preference?
Imported from ODATA-1625
Metadata
Metadata
Assignees
Type
Projects
Status
Closed