SAP Knowledge Base Article - Public

3075058 - Key word 'filter' cannot work as expected when testing Odata Service API in Postman

Symptom

Key word 'filter' cannot work as expected when testing Odata Service API in Postman.

Statement below will be generated in case more than 1 filters are added.

https://host-name/sap/API_MATERIAL_STOCK_SRV/A_MatlStkInAcctMod?$filter=Plant eq '1010'&filter=MatlWrhsStkQtyInMatlBaseUnit eq 10473

Environment

SAP S/4HANA Cloud

Reproducing the Issue

Create API call with tool post man and add more than 1 filters

Cause

'&' is used instead of 'and' in the statement and this is not valid in Odata Service statement.

Resolution

Edit the statement and use the key word 'and' if more than 1 filters are used.

/sap/opu/odata/sap/API_MATERIAL_STOCK_SRV/A_MatlStkInAcctMod?$filter=Plant eq '1010' and MatlWrhsStkQtyInMatlBaseUnit eq 10473 and Material eq 'TG11' and StorageLocation eq '101A'

Keywords

KBA , MM-IM-VDM-SGM , VDM Stock and Goods Movements , MM-IM-VDM-SGM-2CL , VDM Stock and Goods Movements (Public Cloud) , Problem

Product

SAP S/4HANA Cloud 2105