Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix catagorization of guideline severties. #200

Closed
PhilippSalvisberg opened this issue Sep 6, 2023 · 0 comments · Fixed by #201
Closed

Fix catagorization of guideline severties. #200

PhilippSalvisberg opened this issue Sep 6, 2023 · 0 comments · Fixed by #201
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@PhilippSalvisberg
Copy link
Collaborator

In the talk Fighting Bad PL/SQL & SQL I categorised the violations of the following guidelines as bugs:

Id Title Severity in 4.2
G-1080 Avoid using the same expression on both sides of a relational comparison operator or a logical operator. Minor
G-2150 Avoid comparisons with NULL value, consider using IS [NOT] NULL. Blocker
G-3185 Never use ROWNUM at the same query level as ORDER BY. Major
G-4230 Always use a COALESCE instead of a NVL command, if parameter 2 of the NVL function is a function call or a SELECT statement. Critical
G-4250 Avoid using identical conditions in different branches of the same IF or CASE statement. Major
G-5080 Always use FORMAT_ERROR_BACKTRACE when using FORMAT_ERROR_STACK or SQLERRM. Minor
G-7810 Never use SQL inside PL/SQL to read sequence numbers (or SYSDATE) Major
G-9010 Always use a format model in string to date/time conversion functions. Major

Bugs are a blocker IMO. Hence all these guidelines should be blocker according to Severity of a rule. G-4230 is an exception since the violation does not lead to a wrong result, just to slower execution. Hence "critical" is an acceptable severity in this case. For a similar reason, G-5080, G-7810 should be changed to "critical" and not "blocker".

It's probably a good idea to check the severity of all guidelines and amend them if necessary.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant