Reputation: 259
I have a sample file in the below format
Name Description Value
ram ABC 0
sri DEF 0
arjun DEF 5
If the 3rd column $3 contains a value other than 0, need to generate an email.
I can pick the contents of column 3 using awk '{print $3}' file_name
.
Need someone to help me beyond this.
Upvotes: 0
Views: 72
Reputation: 67291
awk '$3!=0{system("mail -s "Subject" [email protected]");}' your_file
Upvotes: 1