Lhamo_rin has asked for the wisdom of the Perl Monks concerning the following question:
I have a data file as such:
"1" { "data1" "test.V1_0"; "StrCatDone" "0"; "seq_name" "sequence.V5_0"; "seq_step" "22"; } "2" { "data1" "test.V1_0"; "StrCatDone" "1"; "seq_name" "sequence.V5_0"; "seq_step" "41"; }
I need to search through each file one block at a time and find instances in which StrCatDone is = 1. When that is true I need to change the following data point, seq_name, from sequence.V5_0 to sequence_$newtext.
I would like some opionions on how best to do this.
Thanks
Code tags added by GrandFather
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Altering data files
by BrowserUk (Patriarch) on Oct 10, 2006 at 13:25 UTC | |
|
Re: Altering data files
by Hofmator (Curate) on Oct 10, 2006 at 13:31 UTC | |
|
Re: Altering data files
by davidrw (Prior) on Oct 10, 2006 at 13:27 UTC | |
|
Re: Altering data files
by jdporter (Paladin) on Oct 10, 2006 at 15:51 UTC | |
|
Re: Altering data files
by codeacrobat (Chaplain) on Oct 10, 2006 at 23:00 UTC | |
|
Re: Altering data files
by systems (Pilgrim) on Oct 12, 2006 at 16:16 UTC |