CLASS.DB OUTPUT:
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 '-60, 60' at line 16
CLASS.DB OUTPUT:
QUERY:
SELECT 
				t1.*,
				t1.id as product_id,
				t2.brand_name, 
				t2.brand_website, 
				t3.unit_name,
				DATE_FORMAT(t1.created, '%d.%m.%Y') as created2,
				IF(t1.name_et != '', t1.name_et, t1.name_et) as name,
				IF(t1.description_et != '', t1.description_et, t1.description_et) as description,
				IF(t1.url_code_et != '', t1.url_code_et, t1.url_code_et) as url_code,
				IF(price_discount > 0 AND price_discount < price, price_discount, price) as current_price,
				IF(price_discount > 0 AND price_discount < price, 1, 0) as is_discounted,
				(SELECT fk_category_id FROM mdl_shop_product_category WHERE fk_product_id = t1.id ORDER BY fk_category_id DESC LIMIT 1) as main_cat_id,
				(SELECT COUNT(*) FROM mdl_shop_product_files WHERE type='image' AND fk_product_id = t1.id LIMIT 1) as images_count FROM mdl_shop_products AS t1
			LEFT JOIN mdl_shop_brands AS t2 ON t1.fk_brand_id = t2.id
			LEFT JOIN mdl_shop_units AS t3 ON t1.fk_unit_id = t3.id WHERE t1.active = 1 AND t1.deleted = 0 AND name_et != '' AND t1.id IN ('1313','1425','1426','1427','1429','1430','1431','1451','1452','1453','1480','1509','1510','1511','1537','1538','2666','2667','3209','3210','3211','3212','3214','3222','3223','3224','3225','3226','3227','3228','3229','3230','3231','3232','3233','3234','3235','3236','3237','3238','3239','3356','3357','3358','3360','4579','4580','4581','4582','4583','4584','4585','4586','4587','4588','4589','4590','4592','4593','4594','4595','4596','4597','4598','4599','4600','4601','4602','4603','4604','4605','4606','4607','4608','4609','4610','4611','4612','4613','4614','5080','5081','5082','5083','5084','5085','5086','5087','5088','5089','5090','5906','5907','5908','5909','5910','5911','5912','5913','5916','5917','5918','5919','5921','5922','5923','5924','5925','5926','5927','5928','5929','5930','5931','5932','5933','5934','5935','5936','5937','5938','5939','5940','5942','5943','5944','5945','5946','5947','5948','5949','5950','5951','5952','5953','5954','5955','5956','5957','5958','5959','5960','5961','5962','5963','5964','5965','5966','5967','5968','5969','5970','5971','5972','5973','5974','5975','5976','5977','5978','5979','5980','5981','5982','5983','5984','5985','5986','5987','5988','5989','5990','5991','5992','5993','5994','5995','5996','5997','5998','5999','6000','6001','6002','6003','6004','6005','6006','6007','6056','6057','6190','6236','6237','6238','6329','6330','6331','6332','6333','6334','6338','6352','6353','6354','6374','6375','6388','6436','6569','6571','6636','6637','8134','8766','8767','8768','8769','8770','8803','8865','8866','8918','8921','8922','8945','8947','8948','8949') ORDER BY priority DESC, id DESC LIMIT -60, 60