Bug? Ctrl+B, Ctrl+Q assigns same alias to both parts of the JOIN
PDinCA
Posts: 642 Silver 1
in SQL Prompt
Version 7.3.0.775
Ends up as:
The right-hand side qualifiers s/b uvu, not UV.
UPDATE uvu SET IncludeInVersionResult = 0 FROM #UniqueVersions uvu WHERE VersionNumber <> 1 AND PromotionID IN ( SELECT PromotionID FROM #UniqueVersions UV WHERE UV.SlotSetID = SlotSetID AND UV.SlotNum = SlotNum AND UV.PromotionID = PromotionID AND UV.ContentID = ContentID AND UV.VersionNumber = 1 AND CAST(UV.AssignedGeographies AS nvarchar(max)) <> CAST(AssignedGeographies AS nvarchar(max)) );
Ends up as:
UPDATE uvu SET uvu.IncludeInVersionResult = 0 FROM #UniqueVersions uvu WHERE VersionNumber <> 1 AND PromotionID IN ( SELECT UV.PromotionID FROM #UniqueVersions UV WHERE UV.SlotSetID = UV.SlotSetID AND UV.SlotNum = UV.SlotNum AND UV.PromotionID = UV.PromotionID AND UV.ContentID = UV.ContentID AND UV.VersionNumber = 1 AND CAST(UV.AssignedGeographies AS nvarchar(max)) <> CAST(UV.AssignedGeographies AS nvarchar(max)) );
The right-hand side qualifiers s/b uvu, not UV.
Jesus Christ: Lunatic, liar or Lord?
Decide wisely...
Decide wisely...
Tagged:
Comments
I've managed to reproduce this locally and logged it in our system, hopefully we'll have a fix soon.
Cheers,
James
Redgate Software
We're really sorry this forum post has slipped under the radar. We've just tested it on the latest version of SQL Prompt and it seems that development work on our aliasing system has solved this issue. Please don't hesitate to let us know if you're still having problems.
Thanks,
Tom
Redgate Software