Find records using epoch time.

How do i find the record which has been edit the last 10 minutes?
from a.txt which has last field is epoch time updated.

10/17/2012 1:47 PM||||||In Use|chicken||1350005487
10/17/2012 2:53 PM||||||Available|chicken||13500000
10/17/2012 3:20 PM||||||In Use|cat||1351000000
10/17/2012 3:22 PM||||||In Use|cat||1351111111
10/17/2012 4:18 PM||||||In Use|bear||1351205987
10/23/2012 3:00 PM||||||Available|cat||1351105487

and write to B.txt like
0/17/2012 4:18 PM||||||In Use|bear||1351205987
10/23/2012 3:00 PM||||||Available|cat||1351105487

Thanks.

# does not work on Solaris
now=$( date +%s)
now=$(( $ now - 600 ))
awk -F '|'  -v when=$now 'when <= $(NF) ' inputfilename

For Solaris use

now=$( perl -e 'print time;' )

since

date +%s 

is not supported.

perl -F'\|' -MTime::Local -alne 'BEGIN{$ten=(timelocal((localtime)[0..5])-600)}{print if $F[$#F]>=$ten;}' input_file