Hi, Please read the whole thread.
I have been working on this script below. It works fine, feel free to copy and test with the INPUT File below as well.
example:
What I need to get is the first column between the pattern
PACKET DATA PROTOCOL CONTEXT DATA and
END
for this case , that will be
OUPUT
I have copied the output from the script.
****************************************
SCRIPT
****************************************
INPUT FILE
****************************************
OUPUT
****************************************
thanks Chubler_XL for taking your time and help me out with this.
Unfortunately, the input file is a little bit tricky. It seems that is trying to look for the numbers, but only displays the placeholder and not the value.
I have been playing around with the values of RSTART and RLENGTH with no luck. Any suggestion?
Chubler_XL
Man that was awesome, It worked really cool.. Thanks again for your time and bearing with me this script!!!!
Saludos.
---------- Post updated at 07:54 AM ---------- Previous update was at 07:37 AM ----------
One more help, Last time I did not realize about some categories might display several times in the input file. For example, category BAOC, it has 4 occurrences, so I need to extract that category and the column beside called STATUS separated by commas
Example:
I have files in below format
file 1:
zxc,133,joe@example.com
cst,222,xyz@example1.com
File 2 Contains:
hxd
hcd
jws
zxc
cst
File 1 has 50000 lines and file 2 has around 30000 lines :
Expected Output has to be :
hxd
hcd
jws (5 Replies)
Hi,
My input files is like this
axis1 0 1 10
axis2 0 1 5
axis1 1 2 -4
axis2 2 3 -3
axis1 3 4 5
axis2 3 4 -1
axis1 4 5 -6
axis2 4 5 1
Now, these are my following tasks
1. Print a first column for every two rows that has the same value followed by a string.
2. Match on the... (3 Replies)
Hi! Is there a way to append column and row header to a file in awk script.
For example if I have
Jane F 39 manager
Carlos M 40 system administrator
Sam F 20 programmer
and I want it to be
# name gend age occup
1 Jane F 39 manager
2 Carlos M ... (4 Replies)