select rtrim ( lpad  ( ' ', 2*level )  ||
               rtrim ( operation )     || ' ' ||
               rtrim ( options )       || ' ' ||
               object_name             || ' ' ||
               partition_start         || ' ' ||
               partition_stop          || ' ' ||
               to_char ( partition_id )
             ) the_query_plan
  from plan_table
  connect by prior id = parent_id
  start with id = 0;

解决方案 »

  1.   

    直接 设置 autotrace on 就可以,,不过要运行完了才能看到, 不过你可以试试用其他的工具,如pl/sql ,按一下f5就可以了,,呵呵,,
      

  2.   

    建议用第三方工具,例如PL/SQL Developer。现在的版本是5.1,去51delphi下载。
      

  3.   

    执行RDBMS/ADMIN/UTLXPLAN。SQL 
    CREATE public synonym plan_table for sys.plan_table
    grant all on plan_table to public
    run sqlplus/admin/plustrce.sql
    grant plustrce to public然后,你在PLUS中键入SET AUTOTRACE ON
    就可以看到执行计划了