You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ORDER BY tabcen.id_sort' at line 16
SELECT tabcen.id, tabcen.wariacje_id, tabcen.artykul_id, tabcen.id_sort, tabcen.cena_detal, tabcen.cena_hurt, tabcen.cena_promo, tabcen.jm, tabcen.widoczny, tabcen.promocja FROM sklep_tabela_pola as tabcen WHERE tabcen.artykul_id = ORDER BY tabcen.id_sort