Adding support for pureQuery to Java projects

You must configure your Java projects to support the development of applications that use the pureQuery API. You can add this support explicitly or you can add it implicitly when you first generate code from a database object or SQL statement. This topic describes how to add this support explicitly.

Procedure

To add support for pureQuery to a Java project:

  1. Right-click your Java project and select Add pureQuery Support. Follow these steps in the Add pureQuery Support wizard.
  2. Follow the instructions in the wizard. For information about the controls on the wizard, click Help in the lower-left corner of the wizard. If the help does not appear, select a control on the Add pureQuery Support page and then click Help again.

Results

After you click Finish, the workbench creates the folder pureQueryFolder in your Java project.

If you are using DB2® for z/OS®, or DB2 for Linux, UNIX, or Windows, this folder contains the files Default.genProps and Default.bindProps. You use these files if you plan to run SQL statements statically from applications that use annotated methods.

Removing pureQuery support: If you want to remove the support for pureQuery from a Java project, right-click the project and select Remove pureQuery Support.
  • If you perform a Clean action on the project by selecting Project > Clean, the workbench does not delete any implementation classes that might exist in your project.
  • If you modify an interface and save the changes, the workbench deletes the corresponding implementation class.

Feedback