01.09.2016 Views

Beginning Oracle Database 11g Administration From Novice to Professional

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

384<br />

CHAPTER 17 SQL TUNING<br />

<br />

<br />

<br />

<br />

<br />

<br />

<br />

<br />

<br />

<br />

<br />

<br />

<br />

<br />

<br />

<br />

<br />

<br />

<br />

Another way <strong>to</strong> identify tuning candidates is <strong>to</strong> examine a STATSPACK report.<br />

STATSPACK reports were discussed in Chapter 16.<br />

Understanding the Causes of Inefficient SQL<br />

We may not even realize that we are dealing with inefficient SQL because powerful hardware<br />

can compensate for much inefficiency. In fact, one simple method of “improving”<br />

performance is simply <strong>to</strong> throw powerful hardware at the problem. 1 In other cases,<br />

a statement may take such little time <strong>to</strong> execute that we may not realize that it is inefficient.<br />

There are many different causes for poor performance of SQL statements, and<br />

there are many solutions; a short essay cannot do them justice.<br />

We should also keep in mind that, given enough time, effort, and money, it is always<br />

possible <strong>to</strong> extract more performance out of an SQL statement. The example used in this<br />

chapter perfectly illustrates the point; we keep improving its performance until we hit the<br />

theoretical maximum level of performance. However, it is not usually possible <strong>to</strong> give so<br />

1. In <strong>Oracle</strong> on VMware, Dr. Bert Scalzo makes a persuasive case for “solving” problems with hardware<br />

upgrades, saying that "Person hours cost so much more now than computer hardware even with inexpensive<br />

offshore outsourcing. It is now considered a sound business decision these days <strong>to</strong> throw cheap<br />

hardware at problems."

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!