具体问题如下图
兄弟怎么一道题发了两遍啊[code="sql"]select a.id,a.name,b.type,(case when exists a.id=b.id then 'Y' else 'N') from a left join b on a.id=b.id;[/code]