I'm trying to filter data from a file and send an email when specific info\error codes are found. The first line of the script is for manipulation, and the second part I got from https://unix.stackexchange.com/a/246872/181400 to complete the email sending part.I need to know about all errors that have 400 id and north,I am trying to realize why I am not getting the full extant of the file-Could it be that it is because the second END statement?     { awk 'BEGIN{print Subject:App Error \nFrom:Server \nTo:email@address.com}   END{printf(%s\015\n, $1 | $2 | $3 | $4)}  END{if($1<399){exit(1)}}' \   /tmp/err.txt || exit; } > (/usr/lib/sendmail -t email@address.com)This is the data I get in the file:     label  responseCode     info data  404     Get info data  404     get user info data  403     create landmark  403     ........ More lines of the same come after this....And this is what I get through the mail:      create | landmark | 403 |  Does anybody have any idea on this matter ?  Thanks!
File manipulation - understanding script output
shell script