Query to view failure detail for a given sql agent job step? I have a sql agent job step that failed for a given date / time.  Is there an MSDB - TSQL query I can run to view the step failure reason given that :

I know the job name.
I know when the job failed.
I know the step number
You should be able to adjust this query to your criteria - taken from What is the Query to display the failed sql jobs
select j.name
    ,js.step_name
    ,jh.sql_severity
    ,jh.message
    ,jh.run_date
    ,jh.run_time
FROM msdb.dbo.sysjobs AS j
INNER JOIN msdb.dbo.sysjobsteps AS js
   ON js.job_id = j.job_id
INNER JOIN msdb.dbo.sysjobhistory AS jh
   ON jh.job_id = j.job_id AND jh.step_id = js.step_id
WHERE jh.run_status = 0