![]() SELECT * FROM table(DBMS_XPLAN.DISPLAY_CURSOR('gwp663cqh5qbf',0)) Get sql_id and child_number for the preceding statement:ĭisplay the execution plan for the cursor: This includes the SQL ID of the statement and optionally the child number. In that case, you must supply a reference to the child cursor to the table function. You can also use the table function DISPLAY_CURSOR to display the execution plan for any loaded cursor stored in the cursor cache. SELECT ename FROM emp e, dept d WHERE e.deptno = d.deptno SELECT * FROM table(DBMS_XPLAN.DISPLAY_CURSOR) To display the execution plan of the last executed statement for that session: Predicate Information (identified by operation id):ĭisplaying a Cursor Execution Plan Using DBMS_XPLAN.DISPLAY_CURSORīy default, the table function DISPLAY_CURSOR formats the execution plan for the last SQL statement executed by the session. | Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time | This query produces the following output: Displaying a Plan Table Using DBMS_XPLAN.DISPLAYĮxecute an explain plan command on a SELECT statement:ĭisplay the plan using the DBMS_XPLAN.DISPLAY table function
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |