select info.* from depart as d LEFT JOIN info_sys as info on d.id = info.dept_name
left join grade g on info.id = g.sysinfo_id
left join matarial m on g.id = m.grade_id
where d.detail_address='详细地址' or g.name='';
select info.* from depart as d LEFT JOIN info_sys as info on d.id = info.dept_name
left join grade g on info.id = g.sysinfo_id
left join matarial m on g.id = m.grade_id
where d.detail_address='详细地址' or g.name='';