我正在尝试从RepDailyInfo
表中获取 DatesRepDailyCollection.IsReceived = 0
以及何时RepDailyCollection
确实有该特定的记录RepDailyInfoID
。这在 sql server 2005 中可能吗?
Select distinct RepDailyInfo.Date
from RepDailyInfo
left outer join RepDailyCollection c
on c.RepDailyInfoID = RepDailyInfo.RepDailyInfoID
where c.IsReceived = 0
or c.IsReceived = null