📅  最后修改于: 2022-03-11 15:04:58.051000             🧑  作者: Mango
SELECT child.Id,
child.Name,
child.ParentId,
parent.Name as ParentName
FROM your_table child
JOIN your_table parent ON child.ParentId = parent.id;