Hi,
I want to extract the field number from its header (first row). A sample data is:
bs om lm bts bm .....
x1 x2 32 43 43 .....
x4 x7 54 23 32 .....
...................... .....
I expect the output to be 4, I need to pass the field name through a C- shell script to the Awk script (key.awk) to get the field number corresponds to the given name.
When I integrate the field name directly in the Awk script, I get the correct the result, otherwise I do not get any results when I use the -v option.
any comments are welcome ..