beowulfkid
Programmer
My input is as below:
Locks:
Address TranHdl Lockname Type Mode Sts Owner Dur HldCnt Att ReleaseFlg
0x07800000208E0340 3 53514C4332453037DF495EFE41 Internal P ..S G 3 1 0 0x0000 0x40000000
0x07800000208DB000 7 53514C4332453037DF495EFE41 Internal P ..S G 7 1 0 0x0000 0x40000000
0x07800000208DA380 7 00000038000000010001A40056 Internal V ..S G 7 1 0 0x0000 0x40000000
0x07800000208DB280 3 0000000200007F0422FB468043 CatCache ..S G 3 1 0 0x0000 0x40000000
0x07800000208E49C0 3 00040101000000000000000054 Table ..X G 3 255 0 0x0000 0x40000000
0x07800000208DC1C0 7 00040101000000000000000054 Table .IS W* 7 1 0 0x0000 0x00000001
example of what I want to do is below:
$ more locks1556528 | awk '$3 == "00040101000000000000000054" {print $0}'
0x07800000208E49C0 3 00040101000000000000000054 Table ..X G 3 255 0 0x0000 0x40000000
0x07800000208DC1C0 7 00040101000000000000000054 Table .IS W* 7 1 0 0x0000 0x00000001
The problem I am trying to solve here is "I do not know the value 00040101000000000000000054" dynamically to compare the $3 with. How I get this value is It is $3 for the row in which $6 = W* as shown below:
0x07800000208DC1C0 7 00040101000000000000000054 Table .IS W* 7 1 0 0x0000 0x00000001
I want to print those two rows in which the $3 is same.
But, this value is the $3 for the row in which $6==W*
Please help !
Thanks Gurus.
Locks:
Address TranHdl Lockname Type Mode Sts Owner Dur HldCnt Att ReleaseFlg
0x07800000208E0340 3 53514C4332453037DF495EFE41 Internal P ..S G 3 1 0 0x0000 0x40000000
0x07800000208DB000 7 53514C4332453037DF495EFE41 Internal P ..S G 7 1 0 0x0000 0x40000000
0x07800000208DA380 7 00000038000000010001A40056 Internal V ..S G 7 1 0 0x0000 0x40000000
0x07800000208DB280 3 0000000200007F0422FB468043 CatCache ..S G 3 1 0 0x0000 0x40000000
0x07800000208E49C0 3 00040101000000000000000054 Table ..X G 3 255 0 0x0000 0x40000000
0x07800000208DC1C0 7 00040101000000000000000054 Table .IS W* 7 1 0 0x0000 0x00000001
example of what I want to do is below:
$ more locks1556528 | awk '$3 == "00040101000000000000000054" {print $0}'
0x07800000208E49C0 3 00040101000000000000000054 Table ..X G 3 255 0 0x0000 0x40000000
0x07800000208DC1C0 7 00040101000000000000000054 Table .IS W* 7 1 0 0x0000 0x00000001
The problem I am trying to solve here is "I do not know the value 00040101000000000000000054" dynamically to compare the $3 with. How I get this value is It is $3 for the row in which $6 = W* as shown below:
0x07800000208DC1C0 7 00040101000000000000000054 Table .IS W* 7 1 0 0x0000 0x00000001
I want to print those two rows in which the $3 is same.
But, this value is the $3 for the row in which $6==W*
Please help !
Thanks Gurus.