要求SQL查出报表的路径和名称,用户姓名和部门。我尝试写了以下SQL,但是导出的数据不完整,求大神解答完善,或者给个现成的参考一下: select (case isnull(g.name,'') when '' then '' else g.name+'/' end)+f.name+'/'+b.name name,b.reportletPath,c.username,c.realname,d.department_name from fr_t_uep a left join FR_REPORTLETENTRY b on a.entryid = b.id left join FR_T_USER c on a.userid = c.id left join V_FR_T_CUSTOMROLE d on c.username=d.username left join FR_FOLDERENTRY f on f.id=b.parent left join FR_FOLDERENTRY g on g.id=f.parent where a. =1 order by userid