谁帮我改改这句SQL!
select a.unitid,a.Projectid,a.ProjectName,a.SalePlan,
a.estimate,a.StartTime,a.EndTime,a.sales,a.InputTime,
a.ForecastMoney,b.Name
from Project a,Archives b
where a.sales=b.userid
and (a.sales='Su' or projectid in (select projectid from ProAccredit where userid='Su'))
当proAccredit中查询记录为空时,会出错,认帮我改一下好吗?