Use of expr to calc differenc ein to epoch values

there are $ signs:

lit-dbracm01-p002:/home/oracle>cat -vet /tmp/longrunmon.out
testinst2,10,1525186184$
testinst,10,1525186184$

is that normal?

yes, it's expected - something else is wrong...

Does the error occur immediately, i.e. right at the begin of the program working on the first input line, or more towards the end of it?
In the code in post#8, shift the DATE_DIFF calculation after the four commented out echo lines, and remove the four comment signs. You may want to add and output a loop counter.

move your DIFF calculation INSIDE the loop - not BEFORE do :
((DATE_DIFF=${CHECK_DATE_1}-${INSERT_TIME}) AFTER the do ...

1 Like

bingo!
fixed.
Thank you so much all, very much appreciate your valued feedback.

Oops! I wasn't replying to the last post; deleted.