New answers tagged query
0
votes
How to change filter "and" to "or"?
You need to overwrite the filter functionality OR condition like this:
$collection->addAttributeToFilter(
array(
array('attribute' => 'someattribute', 'like' => 'value'),
...
Top 50 recent answers are included
Related Tags
query × 287database × 113
magento2 × 93
magento-1.9 × 58
sql × 55
collection × 48
product × 14
magento-1.8 × 11
orders × 11
magento-1.7 × 10
magento2.3 × 9
php × 8
customer × 8
search × 8
catalogsearch × 8
magento-1 × 7
model × 7
magento-2.1 × 6
category × 6
attributes × 6
product-attribute × 6
sales-order × 6
filter × 6
performance × 6
graphql × 6