Tag Archives: oracle

Oracle: Generate a Nice looking Explain Plan from sqlplus

In SQL as the user run: SQL> explain plan for SELECT DISTINCT consumer_id “consumerId”, c.first_name “firstName”, c.last_name “lastName”, c.date_of_birth “dateOfBirth”, c.case_id “caseId”, cd.individual_id “individualId”, cs.family_account_id “familyAccountId” FROM consumer c, child_detail cd, case cs, address a WHERE rownum < = 500 AND c.child_detail_id = cd.child_detail_id (+) AND cs.case_id = c.case_id AND (cs.home_address_id = a.address_id OR cs.mailing_address_id [...]

Getting the full query with Oracle Statspack (9i)

Oracle statspack is essential if you’re trying to track down a performance problem. However, one problem I came across is that the top summary report you get from spreport is only a partial query. This makes it tough for developers to track down exactly where in the code the bad query lives – Especially if [...]