abhay180 has asked for the wisdom of the Perl Monks concerning the following question:
But nothing gets captured in $hier. When i execute this in shell on the same file, i get proper o/p:$mod = "ABC "; $hier = `tac temp.xx | sed -n '/$mod /,/YYY/ p'| grep XXX`;
What i am trrying to do: Search for a string "ABC " in the file Back track till i find "YYY" Print that line w YYY%tac temp.xx | sed -n '/ABC /,/YYY/ p' | grep XXX XXX ZZZZ
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Sed in perl
by 1nickt (Canon) on Oct 11, 2018 at 00:40 UTC | |
by abhay180 (Sexton) on Oct 11, 2018 at 01:08 UTC | |
by soonix (Chancellor) on Oct 11, 2018 at 02:01 UTC | |
|
Re: Sed in perl
by SBECK (Chaplain) on Oct 11, 2018 at 12:48 UTC |