Re: How to switch the RULE hint in outlines hints in 12.2 on standard edition.

From: Neil Chandler <neil_chandler_at_hotmail.com>
Date: Wed, 26 Jun 2019 21:35:34 +0000
Message-ID: <AM0PR10MB20810E03F50EE79423C1FFEF85E20_at_AM0PR10MB2081.EURPRD10.PROD.OUTLOOK.COM>



17 or 26 heuristic rules?

The manuals only ever listed 15 RBO Heuristics. Anyone care to expand the list beyond that?

Access paths and their ranking
Path 1 Single Row by Rowid
Path 2 Single Row by Cluster Join
Path 3 Single Row by Hash Cluster key with Unique or Primary Key Path 4 Single Row by Unique or Primary Key Path 5 Clustered Join
Path 6 Hash Cluster Key
Path 7 Indexed Cluster Key
Path 8 Composite Index
Path 9 Single-Column Index
Path 10 Bounded Range Search on Indexed Columns Path 11 Unbounded Range Search on Indexed Columns Path 12 Sort-Merge Join
Path 13 MAX or MIN of Indexed Column
Path 14 ORDER BY on Indexed Column
Path 15 Full Table Scan

Neil.
sent from my phone

On 26 Jun 2019, at 17:28, Mark W. Farnham <mwf_at_rsiz.com<mailto:mwf_at_rsiz.com>> wrote:

NODS. AND it should be noted that the fact that some of Oracle’s own recursive queries still reporting as using rule does NOT matter regarding the desupport note. Oracle is not the customer and they can do whatever they need to in order to make the RDBMS engine run fast.

The “supported” way to simulate RULE is to write the plan with hints (very often a set of no_merge with clauses is sufficient to model RULE’s choices, which are static and not dependent on cardinality). And once you’ve done that, an outline is not actually needed.

If you cannot simulate the RULE plan with just no_merge hints (and possibly some use_index hints), then I recommend you consult JL and Chris Antognini sites and books and sqlmaria for how to beat your query into submission.

IF you think RULE can be good for your query, that is a declaration that stats don’t matter for that query. You also have no “strait jacket” going this route and if there seems to be an effective hash plan here or there, you and hint that (whereas if RULE still functioned you would be stuck with those (17 or 26, argue amongst yourselves) heuristic rules and capabilities.

mwf

--
http://www.freelists.org/webpage/oracle-l
Received on Wed Jun 26 2019 - 23:35:34 CEST

Original text of this message