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 ('1816','1818','1819','1820','1821','1822','1823','1824','1825','1826','1828','1829','1830','1831','1832','1833','1834','1835','1836','1837','1838','1839','1840','1841','1842','1843','1844','1845','1846','1847','1848','1849','1850','1851','1852','1853','1854','1855','1856','1857','1858','1859','1860','1861','1862','1863','1864','1865','1866','1867','1868','1869','1870','1871','1872','1873','1875','1876','1877','1878','1879','1880','1881','1882','1883','1884','1885','1886','1887','1888','1889','1890','1891','1892','1893','1894','1895','1896','1897','1898','1899','1900','1901','1903','1904','1905','1906','1907','1908','1909','1910','1911','1912','1913','1914','1915','1916','1917','1918','1919','1920','1921','1922','1923','1924','1925','1926','1927','1928','1929','1930','1931','1932','1933','1934','1935','1936','1937','1938','1939','1940','1941','1942','1943','1944','1945','1946','1947','1948','1949','1950','1951','1952','1953','1954','1955','1956','1957','1958','1959','1960','1961','1962','1963','1964','1965','1966','1967','1968','1969','1970','1971','1972','1973','1974','1975','1976','1977','1978','1979','1980','1981','1982','1983','1984','1985','1986','1987','1989','1990','1991','1992','1993','1994','1995','1996','1997','1998','1999','2000','2001','2002','2003','2004','2005','2006','2007','2008','2009','2010','2011','2012','2013','2014','2015','2016','2017','2018','2019','2020','2021','2022','2023','2024','2025','2026','2027','2028','2029','2030','2031','2032','2033','2034','2035','2036','2037','2038','2039','2040','2041','2042','2043','2044','2045','2046','2047','2048','2049','2050','2051','2052','2053','2054','2055','2056','2058','2059','2060','2061','2062','2063','2064','2065','2066','2067','2068','2069','2070','2071','2072','2073','2074','2075','2076','2077','2078','2079','2080','2081','2082','2083','2084','2085','2086','2087','2088','2089','2090','2091','2092','2093','2094','2095','2096','2097','2098','2099','2100','2101','2102','2103','2104','2105','2106','2107','2108','2109','2110','2111','2112','2113','2114','2115','2116','2117','2118','2119','2120','2121','2122','2123','2124','2125','2126','2127','2128','2129','2130','2131','2132','2133','2134','2135','2136','2137','2138','2139','2140','2141','2142','2143','2144','2145','2146','2147','2148','2149','2150','2151','2152','2154','2155','2156','2157','2158','2159','2160','2161','2162','2163','2164','2165','2166','2167','2168','2169','2170','2171','2172','2173','2174','2223','2227','2229','2230','2232','2233','2235','2237','2238','2240','2241','2242','2243','2244','2245','2246','2247','2248','2249','2250','2251','2252','2253','2254','2255','2256','2258','2272','2275','2277','2278','2281','2282','2284','2286','2296','2302','2307','2308','2328','2329','2446','2455','2458','2460','2463','2488','2491','2493','2496','2500','2504','2511','2512','2565','2576','2577','2578','2579','2580','2581','2582','2583','2584','2585','2586','2587','2588','2589','2590','2593','2595','2598','2599','2661','2662','2672','2673','2676','2677','2678','2679','2681','2942','3077','3078','3079','3080','3081','3082','3083','3086','3087','3088','3089','3093','3094','3103','3122','3123','3126','3127','3152','3164','3165','3167','3168','3170','3171','3184','3193','3195','3250','3251','3254','3260','3265','3268','3269','3362','3363','3373','3374','3376','3377','3835','3836','3843','3844','3846','3847','3849','3850','3851','3852','3853','3854','3858','3870','3871','3872','3873','3874','3875','3876','3877','3878','3879','3880','3881','3882','3883','3884','3885','3886','3887','3888','3889','3890','3891','3892','3893','3897','3898','3899','3900','3901','3902','3903','3904','3905','3906','3907','3908','3909','3910','3912','3913','3914','3916','3917','3918','3919','3920','3921','3923','3924','3925','3926','3927','3928','3929','3930','3931','3932','3933','3934','3935','3936','3937','3938','3939','3940','3941','3942','3943','3944','3948','3952','3953','3957','3958','3959','3963','3964','3965','3966','3967','3968','3972','3973','3974','3975','3976','3977','3978','3979','3980','3981','3982','3983','3984','3985','3986','3995','3996','3997','3998','3999','4000','4001','4002','4003','4004','4005','4006','4008','4009','4018','4019','4020','4021','4022','4023','4050','4051','4052','4053','4054','4055','4108','4109','4110','4111','4310','4311','4312','4313','4314','4315','4316','4317','4318','4319','4351','4352','4422','4423','4431','4432','4449','4450','4451','4452','4453','4454','4455','4456','4457','4458','4459','4460','4461','4467','4524','4525','4526','4527','4557','4622','4623','4625','4626','4627','4780','4781','4852','4853','4854','4855','4856','4901','4902','4903','4904','4905','4906','4907','4908','4909','4916','4917','4918','4919','4954','4955','4979','4980','5144','5145','5146','5147','5148','5151','5152','5155','5156','5157','5158','5159','5161','5165','5167','5169','5170','5171','5174','5176','5247','5248','5249','6369','6370','6371','6372','6373','6384','6385','6386','6387','6400','6401','6402','6403','6412','6413','6414','6415','6416','6419','6420','6421','6422','6423','6424','6425','6427','6428','6429','6430','6431','6432','6448','6449','6450','6451','6452','6453','6454','6455','6456','6457','6458','6459','6460','6461','6462','6463','6464','6465','6466','6467','6468','6469','6470','6471','6472','6473','6519','6520','6521','6523','6524','6525','6526','6527','6528','6529','6530','6531','6538','6539','6540','6587','6588','6593','6594','6595','6627','6628','6629','6630','6631','6632','6633','6640','7261','7588','7589','7590','7591','7592','7593','7856') ORDER BY priority DESC, id DESC LIMIT -60, 60