Home > Store > Databases > SQL
SQL Performance Tuning
- By Peter Gulutzan, Trudy Pelzer
- Published Sep 10, 2002 by Addison-Wesley Professional.
- Copyright 2003
- Dimensions: 7-3/8x9-1/4
- Pages: 528
- Edition: 1st
- Book
- ISBN-10: 0-201-79169-2
- ISBN-13: 978-0-201-79169-3
Register your product to gain access to bonus material or receive a coupon.
SQL Performance Tuning is a handbook of practical solutions for busy database professionals charged with managing an organization's critically important data. Covering today's most popular and widely installed database environments, this book is an indispensable resource for managing and tuning SQL across multiple platforms.
Packed with tips, techniques, and best practices, this hands-on guide covers SQL commands and queries over a wide range of conditions and environments. Every facet of the SQL environment is covered, from concurrency control to optimization—and every issue in between. The book includes an overview of each of the most widely used database management systems (DBMS) and provides tuning tips for common day-to-day situations.
Topics covered include:
Whether you are a programmer, consultant, or user, you will find SQL Performance Tuning an indispensable guide to optimizing SQL performance across today's popular database environments.
Throughout SQL Performance Tuning, ideas and techniques are tested on a variety of popular SQL environments, including IBM DB2, Informix, Ingres, InterBase, Microsoft SQL Server, MySQL, Oracle, and Sybase ASE. The book's practical examples are written in ANSI/ISO Standard SQL: 1999.
0201791692B08082002
Related Article
|
19 of 20 people found the following review helpful
By Dmitry Dvoinikov (Ekaterinburg, Russia) - See all my reviews
This review is from: SQL Performance Tuning (Paperback)
This book is rather controversial. I'll begin with a quote from the preface:QUOTE ...we've written it for users and programmers who want to improve SQL performance, no matter what brand of SQL they use. In this book, you'll find tuning tips for common situations... Rather than exploiting the unique features of a single DBMS, we're going to give you ideas that are good for all of the major SQL DBMSs. END QUOTE Sounds good, but ! The biggest idea behind this book is that the authors took 8 most common databases (as per 2002: DB2, Informix, Ingres, Interbase, MS SQL, MySQL, Oracle, Sybase) and sort of compared them on many different subjects. I said "sort of" because you won't find specific recommendations like "DB2 does this better", or "this makes the query faster on Oracle". Instead, the authors came up with this idea - upon each discussed topic they summarize the gain that you might possibly get from using that particular... Read more
9 of 9 people found the following review helpful
By
This review is from: SQL Performance Tuning (Paperback)
There's a lot of ground to cover between being able to put together a SQL query that runs and being able to construct a query that works well. The journey is all the more complicated when you're trying to target multiple RDBMSes, each with its own nuances and oddities. That's where this book shines. By going for breadth--picking 8 major RDMBS and contrasting how they behave in the face of various SQL constructs and optimizations, plus covering some general theory, this book conveys a quality of information that vendor-specific books lack. I knew a fair amount about databases and SQL before picking up the book, and came away with a much better feeling for the terrain, and a new set of optimization tricks.It's unfortunate, but perhaps unavoidable, that some details (e.g. lack of information on transactions and subselects in MySQL) where out-of-date by the time the book was published. It's also unfortunate that the authors were prevented by vendor license agreements from providing... Read more
7 of 7 people found the following review helpful
By MajorTom "Tom" (Speyer) - See all my reviews
This review is from: SQL Performance Tuning (Paperback)
I've just finished chapter 7 and 15. The book offers quite interesting information. It's written very well and easy to understand. Plus a special sense of humor ;-)The information gathered must not be used immediately, but helps when making decisions on database design and usage. This is because, you gain an overview on what the "big eight" do, thus you better understand what your decision could mean, when switching databases. It's a book suitable for both experts and beginners, though basic sql knowledge is expected. |
› See all 10 customer reviews...
Online Sample Chapter
SQL Performance Tuning: Simple "Searches"
Index
Click below to download the Index file related to this title:
Index
Preface
A poorly performing database application can cost each user time, and have an impact on other applications running on the same computer or the same network.
The purpose of this book is to help you improve the performance of your SQL database. It is not an introduction to SQL syntax, not a tuning manual for a specific SQL implementation, and not a guide to design or data modelling. Instead, we've written it for users and programmers who want to improve SQL performance, no matter what brand of SQL they use. In this book, you'll find tuning tips for common situations. Topics that will give you the flavor include: "How to change a query so it will go faster", "What an index does", and "Shifting work from the server to the client."
Rather than exploiting the unique features of a single DBMS, we're going to give you ideas that are good for all of the major SQL DBMSs. Client/server programmers and consultants need to appreciate what can happen when the DBMS changes, or--the most challenging situation--the DBMS is unknown. So we tested all the ideas in this book on eight well-known DBMSs.
A good DBMS already contains a good optimizer. Yet you have picked up a book that promises to help you do your own tuning. That means that either you don't know something ... or you do know something:
You don't know that your DBMS is good ...
That would be true if you're a student, or new on the job. That would especially be true if you're writing queries or programs that should work on more than one DBMS. You're most likely to encounter one of the DBMSs with the largest market shares (based on figures for the year 2000):
- Oracle 33.8%
- IBM 30.1% (prior to acquisition of Informix)
- Microsoft 14.9%
- Sybase 3.2%
- Informix 3.0%
Data from: Gartner Dataquest (May 2001)
You might also run into DBMSs that are popular for web work (like MySQL), for work with Borland products (like InterBase), for desktops (like Access), for mobile and Java interfacing (like Cloudscape), for embedded systems (like Solid), or a host of small fry (like mSQL and gadfly). This book tries to be useful for the common denominator in all products. To use automotive analogies, it's not a "mechanic's guide to tuning the 1999 Cadillac" book, it's a "driver's guide to optimizing performance of modern cars" book—even if you have a manual transmission.
You know that even good tools work better in skilled hands ...
Everybody has heard of sluggish SQL queries, or even whole systems, that some hero(ine) improved with small effort. Usually the improvement is small too, so we will avoid extravagant promises. But we will make you the following guarantees:
One accusation that could be levelled, and to which we plead guilty, is that some of our material is ad-hoc instead of general principles. Of course! There are only a few general principles in DBMS optimization:
Instead of general principals, we will be looking at what can be done with what's likely to be at hand. If we descend sometimes to mere tips and warnings about traps, that's because we've seen over the years that examples of real situations can help people realize what the general rules are. As has often been observed, tips should be based on principles.
The DBMSs that we looked at while preparing this book include IBM DB2, Informix, Ingres II, InterBase, Microsoft SQL Server, MySQL, Oracle, and Sybase (MS-WindowsNT versions). Each was installed and tested using the default switches recommended in the vendors' instructions. To avoid favoring any vendor's idiosyncrasies, all SQL examples in this book are written in ANSI/ISO Standard SQL:1999. Host-language examples are written in C plus ODBC, or Java plus JDBC.
Your DBMS is your pal. We won't counsel you to subvert it, be paranoid about it, or insult it by assuming it's stupid. Rather, as you would with a pal, you should try to get to know it better, and help it to help you.
0201791692P05132002
Table of Contents
Preface.
Acknowledgments.
1. Facilis Descensus Averni.
2. Simple Searches.
3. ORDER BY.
4. GROUP BY.
5. Joins.
6. Subqueries.
7. Columns.
8. Tables.
9. Indexes.
10. Constraints.
11. Stored Procedures.
12. ODBC.
13. JDBC.
14. Data Changes.
15. Locks.
16. Clients and Servers.
17. Cost-Based Optimizers.
Appendix A. Further Reading.
Appendix B. Glossary.
Index. 0201791692T08272002
Downloadable Sample Chapter
Click below for Sample Chapter(s) related to this title:
Sample
Chapter 1
This book includes free shipping!
- Request an Instructor or Media review copy.
- Corporate, Academic, and Employee Purchases
- International Buying Options
Get access to thousands of books and training videos about technology, professional development and digital media from more than 40 leading publishers, including Addison-Wesley, Prentice Hall, Cisco Press, IBM Press, O'Reilly Media, Wrox, Apress, and many more. If you continue your subscription after your 30-day trial, you can receive 30% off a monthly subscription to the Safari Library for up to 12 months. That's a total savings of $199.





