Comments
6 comments
-
Fully agree with Torsten.
And I will add: The rule "unqualified column name" makes no sense when I use alias in ORDER BY clauses. But since SSMS understands and accepts the use of aliases (instead of very long computed statements), the rule should too.
Thanks,
Hans -
Additionally I think the rule "unqualified column name" itself becomes some kind of obsolete if you enable Qualification in SQL Prompt anyway.
-
True. Making me check whether I had that, and ought to disable the rule.
However, I often review legacy scripts, and in these cases it is really beneficial to have such lapses flagged! Often we only realize this sloppiness in WHERE clauses and JOINs when we augment SELECTs or alter the referenced tables so unique field names cease to be unique. I like to just maintain scripts when I work on them, instead of waiting for them to fail. -
Hi @hansjp and @torsten.strauss ,
We are aware of the contextual information in issues. We are hoping to add this in the future.
Best regards,
Krzysztof -
Hi Krzysztof,
thanks for looking into this... -
Sounds good.
Add comment
Please sign in to leave a comment.
I appreciate the option enabling different code rules but I guess there is a general issue here.
Suppose I enabled the rule "unqualified column name" I will get a hint that a specific column is unqualified which is fine but I am not getting a hint to which object the column belongs to anymore cause the bubble is suppressed.
It would be nice to get the warning that there is a violation of the rule but still getting the hint where the column comes from.
Thanks!
Torsten