Skip to content

[FEATURE] Distinguish between severity of Warnings #436

Description

@pgfiore

Which component(s) does this affect?

  • Desktop App
  • CLI Tool
  • SSMS Extension
  • Plan Analysis Rules
  • Documentation

Problem Statement

Since English isn’t my native language, I'll start with a use case to make my life easier.

A query in SSMS (say, the latest 22) doesn't show any specific message, but in Performance Studio (PS) it shows the warning below.

Image

I can only find one a.b.normal message; a table scan shows the predicate: dbo.IB03_GARANZ.UNIV_SEZIONI as IB03.UNIV_SEZIONI=CONVERT_IMPLICIT(numeric(18,0),[@0],0) (and @0 is the forced parametrization at work). And in SSMS, there’s no yellow exclamation mark to highlight warnings.

I have two doubts about PS behavior:

  1. This is not a SARGable issue. The IB03.UNIV_SEZIONI is numeric(), which has a highest precedence on int. And the column is searchable (*).

  2. I like PS showing “hidden” issues, but I’d like to have a way to differentiate between SQL Server warnings and PS help.

The plan is enclosed. Thank you for being so helpful.

(*) I tried the other way around and, in fact, "cast(IB03.UNIV_SEZIONI as varchar) = 5004001" correctly fires a warning in SSMS too.

Proposed Solution

Fix warnings severity
And differentiate between SQL Server warnings and PS "help"

Use Case

drop table if exists #IB03_GARANZ
create table #IB03_GARANZ (UNIV_PK numeric(18,0) primary key, UNIV_SEZIONI numeric(18,0))
select * from #IB03_GARANZ IB03 where UNIV_SEZIONI=1

Alternatives Considered

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions