I have a file - each record quite long - which starts out in the following general format:
and I need to be able to select only records with an O in the indicated location - everything else to be ignored.
I had thought that using something like
would put the value of that field in variable facind but I can't get it to work.
Would appreciate someone pointing me in the correct direction.
Note that the system is AIX 5.2 using Korn shell.
Thanks!
Tom
"My mind is like a steel whatchamacallit ...
Code:
07/11/2007 00:00:10|field2|07112007|field4|MSH|^~\&|SPC|[COLOR=red]O[/color]|IM|E|
and I need to be able to select only records with an O in the indicated location - everything else to be ignored.
I had thought that using something like
Code:
facind=`awk 'BEGIN{FS=OFS="|"}{print $8}' homl.work
would put the value of that field in variable facind but I can't get it to work.
Would appreciate someone pointing me in the correct direction.
Note that the system is AIX 5.2 using Korn shell.
Thanks!
Tom
"My mind is like a steel whatchamacallit ...