gretard / sonar-sql-plugin

SQL language (T-SQL, MySQL, Snowflake, Vertica and PostgreSQL dialects) plugin for SonarQube
GNU General Public License v3.0
79 stars 21 forks source link

BaseRule description is not correct #12

Closed ashitabh closed 3 years ago

ashitabh commented 4 years ago

rImpl.setRuleViolationMessage("Consider using UNION ALL instead of OR in a WHERE clause."); r.setRuleImplementation(rImpl); rImpl.getCompliantRulesCodeExamples().getRuleCodeExample() .add("SELECT name, surname, count from dbo.test where name = 'or' and surname = 'TestOR';"); rImpl.getViolatingRulesCodeExamples().getRuleCodeExample() .add("SELECT name, surname, count from dbo.test where name = 'Test' OR surname = 'Testor';");

gretard commented 3 years ago

Thanks, fixed