I searched for the manual which would explain how to write proper SQL. I never found it and the more I talked to people on which strategy I should follow, the less useful information I seemed to get. The same was true whenever I asked for general rules to decide which index was needed.
DB2 is particularly good at running complex query and analytical processing. Since all modern hardware contains multiple cores and CPUs, and many systems are composed of multiple machines, it is critical that DB2 run individual queries across all available computing resources.
One of the most common maintenance activities performed on a Db2 LUW database is running Runstats on tables and indexes. Accurate database statistics are vital for the Db2 Optimizer to produce the most optimal plans.
In Part 1, I talked about some of the first steps that a developer should go through when it comes to tuning queries. In this article, I will go through the initial steps in evaluating a SQL query using the Db2 explain output.
When it comes to tuning a query, program, or even an application that most developers are not sure where to begin or what may be causing response time issue(s). This article is here to help!