0

Normally for profiling SQL statements I run STRDBG, then enter in the SQL in STRSQL.

However, I have a CGI RPGLE program that does many SQL statements, most dynamic, and I would like to profile all of them to see which is slowing the program down.

What is the best practice for doing this?

ScottR
  • 3,080
  • 3
  • 32
  • 35

1 Answers1

1

I can't speak for best practice but if you like the STRDBG output, wrap your CGI program in a simple CLP that does a STRDBG, calls your real CGI program and then does a DSPJOBLOG to a *OUTFILE.

An alternative is to use the IBM i Navigator that's part of IBM i Access. Drill down through the Databases to SQL Performance Monitors. On the right, at the bottom, click Create a New SQL Performance Monitor. You can choose to monitor a particular program in all jobs.

Buck Calabro
  • 7,558
  • 22
  • 25