SELECt a.nid, GROUP_CONCAt(b.name ORDER BY b.id) DepartmentNameFROM Notes a INNER JOIN Positions b ON FIND_IN_SET(b.id, a.forDepts) > 0GROUP BY a.nid
- SQLFiddle演示

SELECt a.nid, GROUP_CONCAt(b.name ORDER BY b.id) DepartmentNameFROM Notes a INNER JOIN Positions b ON FIND_IN_SET(b.id, a.forDepts) > 0GROUP BY a.nid