与外部联接相关时,如何从表中选择列的子集?
|
select a.cust_xref_id, a.est_hour, a.phone_nbr as number, a.credit_calls, a.credit_rpcs, b.sdp_calls
from #temp0 a
full outer join #temp2 b
on a.cust_xref_id = b.sdp_cust_xref_id
and a.est_hour = b.sdp_hour
and a.phone_nbr = b.sdp_phone
当通过联接在两个表中都不存在数据时,是否有一种方法可以从表b中获得关于sdp_cust_xref_id
,sdp_hour
和sdp_phone
的数据?如果确实存在b.sdp_calls,则列值为空。
没有找到相关结果
已邀请:
1 个回复
届甸衬丝蚕
,它将为您提供表b中的值: