SAP Knowledge Base Article - Public

2785453 - Field is missing in metadata of the Custom CDS API

Symptom

Create a custom CDS view based on Pirmary Data source I_UNITOFMEASURE and published it as an external API.

Field UnitOfMeasure_E was selected, however this field was missed in the metadata of the OData service.

Environment

S/4 HANA Cloud

Reproducing the Issue

  1. Create a custom CDS View based on I_UNITOFMEASURE 
  2. Make sure field UnitOfMeasure_E is selected
  3. Publish the custom CDS view as an external API
  4. Test this API, the field is not showing in metadata

Cause

@Consumption.hidden: true

Standard data source I_UNITOFMEASURE has this property of consumption.hidden:true for that specific field.

So all the datasources referenced the same field will have this property.

Resolution

Modify the Field Properties and make sure the Hidden property is selected to 'False'.

Field Properties.png

Hidden Property.png

Keywords

field, property, properties, edit, metadata, showing, hidden, odata service, missed, custom, external , KBA , BC-SRV-APS-GKE , Generic CDS Key User Editor , Problem

Product

SAP S/4HANA Cloud 1902