这个左外连接怎么做
2张视图
v1
ManufactureID ProductionID WID
1 1 1
1 1 2
V2
ManufactureID ProductionID WID Quantity
1 1 1 3
select isnull(Quantity,0) as 'num' from v1 left join v2
on v1.ManufactureID =v2.ManufactureID
and v1.ProductionID=v2.ProductionID
and v1.WID=v2.WID
预想结果:
num
1
0
可结果为:
num
1
这是为什么????