From 062abe6e7f72fa3ea11d6e9957670f98e1879249 Mon Sep 17 00:00:00 2001 From: Anokhin Alexey Date: Mon, 29 Jun 2020 14:29:19 +0300 Subject: [PATCH] Fixed filtering by specification attributes in ProductLoadAllPaged stored procedure --- .../Nop.Web/App_Data/Install/MySQL.StoredProcedures.sql | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/Presentation/Nop.Web/App_Data/Install/MySQL.StoredProcedures.sql b/src/Presentation/Nop.Web/App_Data/Install/MySQL.StoredProcedures.sql index a09192d1260..9853c6e967b 100644 --- a/src/Presentation/Nop.Web/App_Data/Install/MySQL.StoredProcedures.sql +++ b/src/Presentation/Nop.Web/App_Data/Install/MySQL.StoredProcedures.sql @@ -611,12 +611,8 @@ BEGIN SET @sql_command = concat(@sql_command, ' AND (p.Id in ( select psa.ProductId - from `Product_SpecificationAttribute_Mapping` as psa - INNER JOIN ( - select sao.SpecificationAttributeId - from `SpecificationAttributeOption` as sao - where sao.Id in (', `FilteredSpecs`, ') - ) as sa on sa.SpecificationAttributeId = psa.Id + from `Product_SpecificationAttribute_Mapping` as psa + where psa.SpecificationAttributeOptionId in (', `FilteredSpecs`, ') and psa.AllowFiltering ) )'); end if;