SELECT pr.name_en, pr.id, pr.parent_id, (SELECT name_en FROM ng_products WHERE id=pr.parent_id) as parent_name, IF( parent_id=0, (SELECT group_concat(id) FROM ng_products WHERE parent_id= 1112938) , (SELECT group_concat(id) FROM ng_products WHERE parent_id= pr.parent_id) ) as children_ids, IF( parent_id=0, (SELECT group_concat(name_en) FROM ng_products WHERE parent_id= 1112938) , (SELECT group_concat(name_lv) FROM ng_products WHERE parent_id= pr.parent_id) ) as children_names FROM ng_products pr WHERE id=1112938 GROUP BY id
Layla Cosmetics Ceramic Effect FLUO :: Bergo.lv
Pirms nopērc, Salidzini.lv - Interneta veikali, Kuponi, OCTA kalkulators, KASKO kalkulators, Ātrie kredītiPirms nopērc, Salidzini.lv - Interneta veikali, Kuponi, OCTA kalkulators, KASKO kalkulators, Ātrie kredīti Visi Internetveikali un cenas