Rule Definition
CBO / RBO optimization mode decide on an execution plan based on cost OR set of rules The rule based Optimizer (RBO) mode is deprecated since Oracle 9iR2. By the way the functionality is still present but no new functionality has been included in it and it is no longer supported by Oracle. It is only present to provide backwards compatibility during the migration to the query optimizer (Cost Based Optimizer). It should not be present in production code
In Oracle 9i, RBO was replaced by Cost Based Optimizer or CBO. CBO uses statistics in the dictionary or dynamically samples You should have migrated to CBO at that time, as CBO, even without statistics usually generates better execution plans.
The solution is you remove the RULE hint everywhere and start testing code with optimizer defualt mode (CBO mode)
Remediation
You should always carefully research any hints and try to delete them before applying in production code. Ensure that the queries perform well without RULE hint. One solution could be: Once the SQL has been optimized by adding the hint, the Oracle professional will adjust schema statistics (using dbms_stats) to replicate the execution plan without the hint.
Violation Code Sample
Oracle SQL rule hint:
Select /*+ RULE */ a,b,c from table1;
Fixed Code Sample
Select a,b,c from table1;
Related Technologies
Forms
PL/SQL
Technical Criterion
Efficiency - SQL and Data Handling Performance
About CAST Appmarq
CAST Appmarq is by far the biggest repository of data about real IT systems. It's built on thousands of analyzed applications, made of 35 different technologies, by over 300 business organizations across major verticals. It provides IT Leaders with factual key analytics to let them know if their applications are on track.