A Database Error Occurred

Error Number: 1064

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 'rows, DATE_FORMAT(p.date_created, '%d.%m.%Y') as date_created, p.title, p.id,...' at line 1

SELECT DISTINCT SQL_CALC_FOUND_ROWS null as rows, DATE_FORMAT(p.date_created, '%d.%m.%Y') as date_created, p.title, p.id, p.is_visible, p.product_code, p.date_changed, (select filename from products_images where products_images.products_id = p.id and sort = 0 limit 1) as filename, acc.title as atitle, acc2.title as brandtitle FROM products as p LEFT JOIN article_categories_content acc ON (acc.category_id = p.category_id AND acc.language_id = 3) LEFT JOIN article_categories_content acc2 ON (acc2.category_id = p.product_brand AND acc2.language_id = 3) WHERE is_visible = 1 AND p.category_id = 283 AND p.product_brand = 366 ORDER BY product_code ASC

Filename: models/Products_model.php

Line Number: 58