Forum Discussion

bawright's avatar
bawright
Level 4
12 years ago

Get-BEJobHistory

Hi There I'm running the below command. However it returns more than the last 12 hours. Get-BEJobHistory -JobStatus Error -FromStartTime (Get-Date).AddHours(-12) | ft -auto Any help with would ...
  • bawright's avatar
    12 years ago

    However this works

     

    $a = (Get-Date).AddHours(-12)
     
    Get-BEJobHistory -JobStatus Error | where-object {$_.StartTime -gt $a} | ft -auto
     
    Cheers,
     
    Brettw