The ncurrent expalin facility does that for you in the explain tables.
Look at the db2exfmt command and you can specify how to retrieve what you
need.
The first of the explain table EXPLAIN_INSTANCE has a primary key based on
timestamp so that the same package, section names can be kept by date.
Follows the PK on that table.
D:\SQLLIB\BIN>db2 describe table explain_instance
Column Type Type
name schema name
Length Scale Nulls
------------------------------ --------- ------------------
-------- ----- ------
EXPLAIN_REQUESTER SYSIBM VARCHAR 128 0
No
EXPLAIN_TIME SYSIBM TIMESTAMP 10 0
No
SOURCE_NAME SYSIBM VARCHAR 128 0
No
SOURCE_SCHEMA SYSIBM VARCHAR 128 0
No
SOURCE_VERSION SYSIBM VARCHAR 64 0
No
HTH, Pierre.
--
Pierre Saint-Jacques
SES Consultants Inc.
514-737-4515
"Yuri" <yu**@prodigy.net> a écrit dans le message de news:
Uw***************@newssvr33.news.prodigy.com...
Does anybody have a tool to store/retrieve explained sql? We're running
DB2 8.2 on AIX. We would like to be able to compare old saved explains to
the current ones and see if anything changed.
Thanks,
Yuri