Search

Table of Contents
Refactoring SQL Applications, 1st Edition
BOOK:
Refactoring SQL Applications, 1st Edition
Browse by Category
 
 
Hide Left Column
Refactoring SQL Applications, 1st Edition
Refactoring SQL Applications, 1st Edition
by Stephane Faroult; Pascal L'Hermite

Publisher: O'Reilly Media, Inc.
Pub Date: August 22, 2008
Print ISBN-13: 978-0-596-51497-6
Pages: 304
Slots: 1.0
Start Reading
Buy Print Version
Overview

What can you do when database performance doesn't meet expectations? Before you turn to expensive hardware upgrades to solve the problem, reach for this book. Refactoring SQL Applications provides a set of tested options for making code modifications to dramatically improve the way your database applications function. Backed by real-world examples, you'll find quick fixes for simple problems, in-depth answers for more complex situations, and complete solutions for applications with extensive problems. Learn to:

  • Determine if and where you can expect performance gains

  • Apply quick fixes, such as limiting calls to the database in stored functions and procedures

  • Refactor tasks, such as replacing application code by a stored procedure, or replacing iterative, procedural statements with sweeping SQL statements

  • Refactor flow by increasing parallelism and switching business-inducted processing from synchronous to asynchronous

  • Refactor design using schema extensions, regular views, materialized views, partitioning, and more

  • Compare before and after versions of a program to ensure you get the same results once you make modifications

Refactoring SQL Applications teaches you to recognize and assess code that needs refactoring, and to understand the crucial link between refactoring and performance. If and when your application bogs down, this book will help you get it back up to speed.

 
Editorial Reviews
Product Description
What can you do when database performance doesn't meet expectations? Before you turn to expensive hardware upgrades to solve the problem, reach for this book. Refactoring SQL Applications provides a set of tested options for making code modifications to dramatically improve the way your database applications function. Backed by real-world examples, you'll find quick fixes for simple problems, in-depth answers for more complex situations, and complete solutions for applications with extensive problems. Learn to:

  • Determine if and where you can expect performance gains
  • Apply quick fixes, such as limiting calls to the database in stored functions and procedures
  • Refactor tasks, such as replacing application code by a stored procedure, or replacing iterative, procedural statements with sweeping SQL statements
  • Refactor flow by increasing parallelism and switching business-inducted processing from synchronous to asynchronous
  • Refactor design using schema extensions, regular views, materialized views, partitioning, and more
  • Compare before and after versions of a program to ensure you get the same results once you make modifications

Refactoring SQL Applications teaches you to recognize and assess code that needs refactoring, and to understand the crucial link between refactoring and performance. If and when your application bogs down, this book will help you get it back up to speed.

 
Reader Reviews From Amazon (Ranked by 'Helpfulness')
Average Customer Rating:based on 2 reviews.
Its the context that counts, 2009-03-02
Reviewer rating:
Faroult and Hermite focus their attention on relatively classical SQL optimizations. The gist of their advice is that developers running SQL code need to leverage the database engine's optimizer. To do that, they offer relatively common advice: use set operations, avoiding procedural code in your sql code whenever possible; minimize the number of visits to a table; and minimize the number of times your code has to scan a given table. Most of the content of the book is spent offering techniques for achieving these objectives. For developers without a lot of experience writing SQL intensive applications, the authors provide a relatively accessible discussion of these techniques.

Outside of that, the authors include a chapter called `Testing Framework' that addresses one of the key requirements of any refactoring effort: creating and maintaining a library of unit tests that allows us to prove that our code is correct. When writing database code, and particular code whose performance may vary based on the amount of data being processed, unit testing can be a bit of a challenge due to the typical case where developers are developing locally on databases that contain small data sets. In this chapter Faroult and Hermite offer some data generation techniques and some mechanisms for automating the comparison of resulting outputs.

What I like about this book is that unlike books on optimizing the performance of a particular database product, this book tries to elevate the discussion to the level of optimizing the performance of an application that contains a substantial amount of realistic database code. It should enable developers to analyze their code in the context of the business objectives that it is trying to fulfill, rather than the context of the database engine in which it is executing. For that reason alone, I am recommending it to the database developers on my team.
Too much focus on performance tuning, 2008-12-02
Reviewer rating:
Performance tuning of a database application is a minor part of refactoring a SQL application. In 2008, many programmers found themselves inheriting large applications running on thousands of stored procedures written in PL-SQL, TSQL - great stuff during the hey days of client-server programming era circa the 80s and 90s. For those who are looking for a book to help with the re-design, re-plumbing i.e. refactoring of SQL applications, this book will not help much.

Much of this book is focused on the issue of tuning data model, tuning SQL queries etc With the current server processing power, caching, bit-mapped indices, and a plethora of SQL tuning tools, performance tuning is no longer such a major concern in a SQL refactoring project.

If you are looking for discussion on building unit tests, building wrapper, sprout, identification of seams etc, you should look else where.

 
Some information above was provided using data from Amazon.com. View at Amazon >
Refactoring SQL Applications, 1st Edition
Refactoring SQL Applications, 1st Edition
by Stephane Faroult; Pascal L'Hermite

Publisher: O'Reilly Media, Inc.
Pub Date: August 22, 2008
Print ISBN-13: 978-0-596-51497-6
Pages: 304
Slots: 1.0
Start Reading
Buy Print Version
Company | Terms of Service | Privacy Policy | Contact Us | Help | 508 Compliance | Subscribe Now
© 2009 Safari Books Online. All rights reserved.