Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
Return value of awk
Name: sivakarthik Date: October 5, 2005 at 02:36:17 Pacific OS: Unix CPU/Ram: 512
Comment:
How to get the return value of a awk in a shell script? awk -F['|'] '{print $6}' file.txt
In the above if the column 6 is null the script fails. How can I get the return value to do a check after this.
Thanks Siva
Hi, I'm trying to replace a column in a comma seperated file with a column in another file using sed/awk. Can anyone help me.
Summary: Hello, I need to get a return value of 0 if the format is correct or 1 if the format is incorrect? here is an example? awk -F[.] '($1 ~ /^[0-9]+$/) && ($2 ~ /^[a-zA-Z0-9]+$/)' file1.txt cat file1.txt ...
Summary: Hi, I'm not able to get the value of 200th field using awk. Can you please help me Thanks Siva Hi, I'm trying to replace a column in a comma seperated file with a column in another file using...
Summary: I wanted to get a return value of 1 if the first two lines exist in the file1.txt. The awk statement is working for the 3rd line but not for the first two lines. The NF works if I run it from the comm...