Fatal error:
Query: SELECT webwinkel_producten.*,if(((Aanbieding_vanaf="1970-01-01" or Aanbieding_vanaf<="2017-10-20") and (Aanbieding_totenmet="1970-01-01" or Aanbieding_totenmet>="2017-10-20") and (Aanbiedingprijs>0) ),Aanbiedingprijs,Verkoopprijs) as Prijs, Merknaam, ( select sum(Product_voorraad) from webwinkel_subproducten where Product_id=webwinkel_producten.ID) as SubVoorraad, ( select count(*) from webwinkel_subproducten where Product_id=webwinkel_producten.ID) as SubAantal, ( select Naam from (select * from webwinkel_subproducten order by Volgorde ASC, ID ASC) as xx where xx.Product_id=webwinkel_producten.ID group by Product_id ) as InhoudSub FROM webwinkel_producten LEFT JOIN webwinkel_merken on (Merk_ID=webwinkel_merken.ID) where (webwinkel_producten.Zichtbaar=1 and (webwinkel_producten.Verkoop_vanaf="1970-01-01" or webwinkel_producten.Verkoop_vanaf<="2017-10-20") and (webwinkel_producten.Verkoop_totenmet="1970-01-01" or webwinkel_producten.Verkoop_totenmet>="2017-10-20")) and (( webwinkel_producten.ID in (select Product_id from webwinkel_producten_inhoud where Connect_id=5 and connect_type="Subcategorie") or webwinkel_producten.ID in ( select Product_id from webwinkel_subcategorieen left join webwinkel_producten_inhoud on (webwinkel_subcategorieen.ID = webwinkel_producten_inhoud.Connect_id ) where Parent_id=5 and Connect_type="Subcategorie" ) )) limit -16,16
Error: 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 '-16,16' at line 21