SAP Knowledge Base Article - Public

3622384 - 400 Bad Request error message appears while using OData API: "Failed to fetch the data preview."

Symptom

  • When querying different entities 400 Bad Request error is thrown.
  • Example error message:
    "Failed to fetch data preview.
    We can provide the following information to assist either you or an SAP engineer to solve the issue:
    Correlation ID:
    HTTP Status: 500 error
    Error Code: getDataSetFailed
    Technical Message: Failed to fetch the data. Error in getDataSet. Failed to get dataset data for /FormCustomSection. Cause 1: HTTP/1.1 400 Bad Request{"error" : { "code" : "COE_GENERAL_BAD_REQUEST", "message" : { "lang" : "en-US", "value" : "[COE0018]FormDataId, formContentId and secIndex can not be null or empty!" } } } Code:99999;"

Environment

SAP SuccessFactors Performance Management

Reproducing the Issue

  1. Query for example FormCustomSection without setting value for formDataId, formContentId or sectionIndex.
  2. See the error message.

Cause

The request is malformed, as the syntax of the query is invalid.

Resolution

Correct the syntax of the request according to the description in guide. For example, when querying FormCustomSection, provide the entity key predicates: formContentId, formDataId and sectionIndex.

To get more information on the invalid syntax of the request, go to the Developer Trace in the Log Viewer and search for the log entry identified by the log entry ID. You can find the log entry ID in the error response that is returned by the service.

See Also

FormCustomSection

Keywords

performance form, entity, fail, composite key, PMGM, OData API, 400 error, bad request, fetch, data, getDataSet, FormCustomSection, syntax, query, null, empty, Failed to fetch data preview , KBA , LOD-SF-PM-API , Webservices, OData APIs , How To

Product

SAP SuccessFactors HCM Core all versions ; SAP SuccessFactors Performance & Goals all versions