Детская одежда
FROM newodejda.tree LEFT JOIN newodejda.tree AS t2 ON t2.pid=tree.id AND t2.publish='Y' LEFT JOIN newodejda.altercats ON altercats.pid=tree.id WHERE (t2.id IS NOT NULL OR altercats.id>0) AND tree.pid=1583 AND tree.catalog=1 AND tree.publish='Y' GROUP BY tree.id ORDER BY tree.oid

жёлтые ценники - цена действительна при покупке размерными рядами на цвет