'MaxLength' property which shows the maximum length of a field in metadata of an OData service doesn't show values for CodeText properties like PriorityCodeText, SourceCodeText, StatusCodeText etc.
SAP Cloud for Customer
Reproducing the Issue
- Go to Administrator work center
- Go to OData Service Explorer
- Select the OData service 'c4codataapi'
- Select Test
- Select the OpportunityCollection
You see that there is no value for the field MaxLength for properties like PriorityCodeText, SourceCodeText and StatusCodeText.
The same can be observed by checking the metadata using the following URL: myXYZ.crm.ondemand.com/sap/c4c/odata/v1/c4codataapi/$metadata (XYZ represents the number of the tenant).
Code text properties are dynamic properties of 'string' data type without any fixed length. That's why 'MaxLength' doesn't show any value in both OData console and $metadata of service.
This is a standard behaviour of the system.
MaxLength, $metadata, CodeText , KBA , AP-RC-ODF , OData framework (C4C Only) , Problem