Cybersecurity
DevOps Cloud (ADM)
IT Operations Cloud
How can I return the total duration of test executions for my report?
The following sample SQL query will calculate the duration of a
test run. Please note that you must change the dbo owner name to
suit your own database before this query will run
successfully.
SELECT
edr.ExecDefRunID_pk_fk as RunID,
edr.execservername as machine,
edr.passedcount as pass,
edr.failedcount as fail,
edr.notexecutedcount as notrun,
ex.duration
FROM
TM_ExecDefinitionRuns as EDR
inner join TM_Executions as EX ON
edr.ExecDefRunID_pk_fk = ex.ExecutionID_pk
WHERE
(e.g. looking for runs on a particular day)
Year(ex.ExecutionTimestamp) = 2009
and month(ex.ExecutionTimestamp) = 08
and day(ex.ExecutionTimestamp) = 13
(e.g. looking for a specific run for e.g. troubleshooting)
and edr.ExecDefRunID_pk_fk = 15361