Oracle: SQL Hints — leading, use_nl, ordered

leading

    leading(a) 即指示在Nested Loop时使用a表作为Outer Loop

use_nl

    use_nl(a) 指示连接a表时,要使用Nested Loop并指定a作为Inner Loop

ordered

   select /*+ ordered */ … from t1, t2, t3 where t1.c = t2.c and t2.c = t3.c 指示:先找出t1的记录,然后根据它找出t2的记录,最后再根据t2的结果找出t3的记录

  

Leave a Comment

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.