If I am reading the question correctly, I would use a modified version of dpuu's parent post.
sort -u -t '|' infile1 infile2 | perl myprog.pl
And just have myprog.pl look for lines where the leading key is repeated two lines in a row. If the timestamp was the
same in both files, there will be only one row (-u means make
unique).
-jack |