Results 1 to 2 of 2
  1. #1
    Join Date
    May 2004

    Unanswered: Program / column association

    DB2, OS/390

    Is there a utility I can run which will list tables & columns accessed by program name?

    Thanks in anticipation.

  2. #2
    Join Date
    May 2003
    If you rebind all the plans/packages with Explain = Yes, you can query the plan_table to find out which programs access which tables. This will work with statically bound plans/packages (embedded SQL) and not ad-hoc queries or dynamically prepared SQL statements. But you can manually explain ad-hoc queries with the SQL statement EXPLAIN if you know what the SQL statements are.

    Also, the plan_table will only tell you the tables and not the columns, although you can create a statement table as part of the explain process. See the "Administration Guide" or "Application Programming and SQL Guide".

    You could also query the DB2 catalog to associate plans, tables, and statements.
    Last edited by Marcus_A; 05-04-04 at 19:09.
    M. A. Feldman
    IBM Certified DBA on DB2 for Linux, UNIX, and Windows
    IBM Certified DBA on DB2 for z/OS and OS/390

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts