We double-checked and analysed the situation from CAP side, with these outcomes ....
The relevant CDS types are specified as follows (from the very beginning of CDS):
CDS Type | Remarks |
---|---|
DateTime |
sec precision |
Timestamp |
µs precision, with up to 7 fractional digits |
"second precision" means 0 fractional digits, of course.
The cds compiler maps the CDS types to OData as follows (always did so):
CDS Type | OData v4 |
---|---|
DateTime |
Edm.DateTimeOffset |
Timestamp |
Edm.DateTimeOffset with Precision="7" |
The OData standard specifies for Edm.DateTimeOffset
attribute Precision
:
The value of Precision is a number If not specified for a temporal property, the temporal property has a precision of zero. ("temporal" in there means date/time related data)
The improved input validation in the New OData Adapter (NOA) corrects quite some glitches of the former external OData lib we used. One of which is checking on value and precision ranges of numbers and date/time values to protect applications from late data loss surprises due to unexpected truncation → was requested by many stakeholders/customers.
Does that help?