cancel
Showing results for 
Search instead for 
Did you mean: 

searchCriteria conditionType "IN" does not work for multiple categories in /V1/products

searchCriteria conditionType "IN" does not work for multiple categories in /V1/products

Hi Magento Team,

 

I am facing Issue to search criteria for products search with condition_type (IN) with magento2 REST API. My search url is following

 

http://localhost/merkdoo/index.php/rest/pricesmarte/V1/products?searchCriteria[filter_groups][0][filters][0][condition_type]=eq&searchCriteria[pageSize]=10&searchCriteria[filter_groups][0][filters][0][field]=category_id&searchCriteria[filter_groups][0][filters][0][condition_type]=in&searchCriteria[filter_groups][0][filters][0][value]=2121,2145,2151,2164,2169,96,97,98,99,100,101,102,104,105,107,2190&searchCriteria[currentPage]=1&searchCriteria[sortOrders][0][field]=name&searchCriteria[sortOrders][0][direction]=ASC

 

 

I try to resolve this Issue at my end and after modification in core file I am able to get the result.

 

So I want to know that is it will affect any other functionality of magento2.

 

I make changes here as: 

file Path: vendor/magento/zendframework1/library/Zend/Db/Adapter/Abstract.php

I replace on the line number 872

Before: 

foreach ($value as &$val) {

 

After: 

foreach ($value as $val) {

 

Kindly Let me know, Is the magento2 system functionality will defected by this one.

 

Kindly update me.