--- /dev/null
+select
+ l.job, l.stepno, l.testid, l.status,
+ r.job, r.stepno, r.testid, r.status
+from
+ (select * from steps where flight=110909) l
+ full outer join
+ (select * from steps where flight=110951) r
+on
+ regexp_replace(l.testid,'\([0-9]*\)$','') =
+ regexp_replace(r.testid,'\([0-9]*\)$','')
+ and
+ l.job=r.job
+ and
+ (l.stepno=r.stepno or l.stepno+1=r.stepno)
+where
+ coalesce(r.testid,'') != 'syslog-server'
+ and
+ (l.testid is null or r.testid is null or l.status!=r.status)
+order by
+ coalesce(l.job, r.job),
+ l.stepno, r.stepno,
+ l.testid, r.testid;