This is a small tool that converts a given Consistency Token of a bindfile / package into the timestamp format.

>>--- dbtupreptime --- CT ---><

Syntax diagram

Having a bindfile, you can display its Consistency Token (which represents the point in time, when the prepare for a program - going to be compiled - was done) using the db2bfd -b command (displays the bind file header; Element name = <timestamp>). If the bindfile was bound against a database you can query the Consistency Token using the statement:

SELECT uniq_id FROM syscat.tables WHERE pkgschema = '<SCHEMA>' AND pkgname = '<NAME>'

Sample SQL statement

Calling the program with its only parameter, the conversion is made and the resulting timestamp is printed out; the returncode is zero. If the conversion cannot be done, an error message is displayed; the returncode is nonzero.