View optimizer messages with Explain SQL

Explain SQL extracts optimizer access method information for SQL embedding in packages, triggers, procedures, or functions.

To have more parameters of your program explained:

  1. In the System i Navigator window, expand the system you want to use.
  2. Expand Databases.
  3. Expand the database and schema that contains the object you want to explain.
  4. Right-click on the object and select Explain SQL.

The information that results is the same as running a PRTSQLINF CL command.