代码中的Snippit:
FROM JobsView j
INNER JOIN CostItemsView a
ON j.BidMasterJobUID = a.BidMasterJobUID
LEFT JOIN ResourceEmploymentsView b
ON a.BidMasterJobUID = b.BidMasterJobUID and a.WbsCode = b.CostItemWbsCode
LEFT JOIN ResourcesView c
ON c.BidMasterJobUID = b.BidMasterJobUID and c.UID = b.ResourceUID
其中ResourcesView在视图中的所有嵌套循环内部联接上导致我的“No Join Predicate Warning”(仅在我重建索引时才开始显示)
来自视图的代码:
FROM dbo.Resources AS a
INNER JOIN dbo.ResourcesCalculatedValues AS b
ON b.UID = a.UID AND b.BidMasterJobUID = a.BidMasterJobUID
INNER JOIN dbo.ResourcesReferencedData AS c
ON c.UID = a.UID AND c.BidMasterJobUID = a.BidMasterJobUID
注意:此视图在我的查询中使用了两次,并且两次都没有出现连接谓词警告。
另外值得一提的是我的行为vs est行是关于加入383行为与62,302 est的所有3个查询的关闭。也许与它有关?