You can use pureQuery client optimization to capture and control the SQL statements that are issued by a Java™ application. For example, you can substitute an SQL statement that executes poorly against a database with a SQL statement that has improved performance.
You can configure applications that execute SQL statements dynamically against a DB2® database to instead execute the SQL statements statically.
Executing SQL statements statically provides significant benefits including reducing resource consumption, improving diagnostics, improving security, and providing greater repeatability of SQL performance. The process of configuring an application to use pureQuery client optimization and switching the application from dynamic to static execution of SQL statements does not require modification to the application source code.
Applications that are enabled with pureQuery client optimization might require some additional steps when they are migrated from development and test to production. For example:
- Running the application exercising all the paths that issue SQL statements when capturing SQL statements
- Defining the data sources when configuring the application to use pureQuery Runtime
- Validating the results of SQL statements that you modified
- Ensuring that the performance of SQL statements that you modified is acceptable
Applications that use one of the common Java data access frameworks such as Hibernate, iBatis, and Java Persistence API (JPA) can also be enabled with pureQuery client optimization. Most frameworks use JDBC to access a relational DBMS. pureQuery client optimization handles these frameworks as it does any other JDBC application.