SAP Knowledge Base Article - Public

3278751 - Unable to query candidate with email id using Candidate ODATA API

Symptom

When trying to query candidates and filtering by email address, there are no results, even though the candidates exist in the system.

Environment

SAP SuccessFactors Recruiting Management

Reproducing the Issue

The issue can be reproduced with Postman:

  1. GET /odata/v2/Candidate?$select=candidateId,contactEmail,firstName,lastName,primaryEmail&$filter=primaryEmail eq 'sap+test@dummy.com'
  2. The query returns no results

Cause

There are special characters in the filter/filters used that are not encoded, i.e. sap+test@dummy.com when filtering by email address. In this example, the "+" icon is not supported if not encoded. 

Resolution

Please refer to this documentation on the SAP Help Portal to find out unsupported characters and how to encode them: Handling Special Characters.

i.e. For the above example, the filter should look like this: sap%2Btest@dummy.com

/odata/v2/Candidate?$select=candidateId,contactEmail,firstName,lastName,primaryEmail&$filter=primaryEmail eq 'sap%2Btest@dummy.com'

This applies to any filters (i.e. contactEmail, firstName, lastName, and so on) used in the URI. 

See Also

Handling Special Characters


Keywords

API, OData, query, get, candidate, email, address, primary, first, last, name, calling, data , KBA , LOD-SF-RCM-API , Webservices & APIs , LOD-SF-RCM-INT , Integration Center & Intelligent Services , Problem

Product

SAP SuccessFactors Recruiting all versions