COGNOiSe.com - The IBM Cognos Community

IBM Cognos 10 Platform => Cognos 10 BI => Report Studio => Topic started by: terrysnook on 16 Sep 2014 10:08:46 AM

Title: Determine report end timestamp using Audit package
Post by: terrysnook on 16 Sep 2014 10:08:46 AM
Hi, I'm hoping someone can help.  I want to calculate a report's ending Time stamp using the Run Reports query subject in the Audit Package.
Selecting unique Report IDs
Selecting the minimum Time stamp for each unique Report ID.  This is what I'm calling Report begin Time stamp.
Selecting the sum of the Execution time for unique Report IDs and converting to seconds (can also convert to minutes, hours, days, weeks, months, years if an easy solution requires it)

I'd like to add the sum of the Execution time to the Report begin Time stamp to calculate the Report end Time stamp.  Is there an elegant and accurate way to do this?

Thank you!
Title: Re: Determine report end timestamp using Audit package
Post by: Francis aka khayman on 16 Sep 2014 09:08:01 PM
you might need to do some research here...

find out what backend database is used for your audit tables.

from there you can research how timestamp is stored internally. might be stored as a certain number (seconds?). if you can retrieve that number (by casting?) or converting your timestamp into seconds, then and add the execution time (in seconds), then convert it back to timestamp.

vendor specific functions (back end database functions) will be very helpful here.
Title: Re: Determine report end timestamp using Audit package
Post by: cognos2014 on 21 Jan 2015 12:39:47 PM
Hi Terrysnook, any luck calculating the execution time? I have a similar need where I need to know how long the report took to run.

Thanks!
Title: Re: Determine report end timestamp using Audit package
Post by: bdbits on 21 Jan 2015 06:03:28 PM
You can get the execution times from the audit package and sample reports you can get for free from IBM, so you don't have to go audit database diving.