Ian Skinner wrote: > I remember a thread recently where DBMS execution plans where used to debug a > problematic query. I now have a need to explore this on an Oracle 8/9 system > for documentation and debugging. I'm off to Google to see what I can find > out on how one does this with Oracle systems. But I though I would also ask > here since this group can often answer questions faster and more usefully > then what I can Google up easily. > > So how does one actually capture and view these execution plans with an > Oracle DBMS?
First you need a plan_table. It can be generated from the utlxplan.sql script in rdbms/admin if it isn't there yet. Next, start a transaction, delete all rows from the plan_table, run your query with "EXPLAIN PLAN FOR " prepended which will populate the table, display the result from plan_table and rollback. Jochem ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:195040 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

