[sas@trcv003 ~]$ bhist -l $(bhist -t -T "$(date -d "2 weeks ago" +%Y/%m/%d/%H:%M),$(date +%Y/%m/%d/%H:%M)" | egrep -o 'Job.[<>0-9]+.exited.with.exit.code.[0-9]+' | sed 's/[<>]//g' | cut -d' ' -f2) |sed ':a;N;$!ba;s/\n //g' | egrep -o '(^Job.<[0-9]+>.*User.<[A-Za-z0-9]+>|Exited.with.exit.code.[0-9]+)' | sed ':a;N;$!ba;s/\nExited/ exited/g'
Job <36178>, Job Name <SAS Enterprise Guide_SASApp - Workspace Server_0B496297-E9D2-3048-B8FC-2358884D8AD2>, User <sassrv> exited with exit code 1
Job <36296>, Job Name <test2>, User <sas> exited with exit code 102
Job <36297>, Job Name <test2>, User <sas> exited with exit code 102
Job <36299>, Job Name <test2>, User <sas> exited with exit code 102
Job <36300>, Job Name <test2>, User <sas> exited with exit code 102
Job <36301>, Job Name <test2>, User <sas> exited with exit code 102
[sas@trcv003 ~]$
... View more