select c1.category_name, g.Goods_name
from goods as g
left join category as c on c.id_category = g.id_category
left join category as c1 on c1.id_category = с.parent_Id
select c.category_name, c.parent_Id, g.Id_goods, g.Goods_name, c.id_category
from goods as g
left join category as c on c.id_category = g.id_category