SELECT A.KeyID, A.Name, A.ShortDescription, A.Description, A.Price, A.Weight, A.ModifyDate, A.UseWares, A.DaysToWare, A.Quantity, A.TaxID, A.Code, A.Manufacturer, A.Unit, A.MinOrder, A.Alias, A.gCertificates, A.CertDescription, A.MetaDescription, A.Youtube, A.BigUnit, A.BigQuantity, A.Keywords, A.ShowInGeneralCommercial, A.DiscountPrice, A.RemovalProduct, A.DiscountPriceDueDate, A.EventDate, A.EventDateEnd, A.Address, A.Zip, A.City, A.EAN FROM Product A, ProductCategory B WHERE () AND A.LanguageID = 1 AND NOT (A.UseWares = 1 AND A.HideWhenOut = 1 AND A.Quantity < 1) AND A.ShowDate <= NOW() AND A.HideDate >= NOW() AND A.Visible = 1 AND A.KeyID = B.ProductKeyID ORDER BY Price LIMIT 150
You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ') AND A.LanguageID = 1 AND NOT (A.UseWares = 1 AND A.HideWhenOut' at line 5