9 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I have 500 MB of file.
I want to retain first line and last line of the file.
I am unaware of deleting lines from a file in PERL.
How can i do it in PERL?
Regards
VANITHA (3 Replies)
Discussion started by: vanitham
3 Replies
2. Shell Programming and Scripting
Hi,
I want to match the time in the file and retrieve those contents of the file.
I am taking only first two parameters of localtime(time) function minutes and seconds so partial match i am performing.
For Example
$start = "14:23";
$end = "14:30";
I am matching file contents... (3 Replies)
Discussion started by: vanitham
3 Replies
3. Shell Programming and Scripting
I have some character strings and I would like to know how can I remove them using perl. My file contains the following output shown below.
An example of a string in the file:
+ netmck(uid=500)-root
+ netmck(uid=500)-root
+ netmck(uid=500)-root
+ netmck(uid=0)-root
.
.
.
I would... (1 Reply)
Discussion started by: smlushing
1 Replies
4. Shell Programming and Scripting
Attached is a streamed EDI ANSI X12 output where the segment terminator/delimiter is a tilde ~ character.
Is it possible to do the following pseudo-code in a unix script (using either sed, awk and/or grep)?
Open file StreamedOutput.txt
Search for ISA and delete the data up to the tilde ~ char... (7 Replies)
Discussion started by: sapedi
7 Replies
5. Shell Programming and Scripting
Hi
Is there any command to scan thru a file looking for 2 consecutive blank lines and if any remove one of them. Please let me know.
Regards,
Tipsy (6 Replies)
Discussion started by: tipsy
6 Replies
6. Shell Programming and Scripting
Can anyone tell me what could be the solution to following :
I have one .txt file which contains some seed information. This seed may appear multiple time in the file so what I want do is if this seed appears again in the file then that line should be removed.
here is the contents of .txt... (5 Replies)
Discussion started by: dipakg
5 Replies
7. Shell Programming and Scripting
I have a variable dynamically generated
$batch = /dataload/R3P/interface/Bowne/reports/RDI00244.rpt
Now I'd like to strip '/dataload/R3P/interface/Bowne/reports/RDI' and '.rpt' from this variable
my output should be only 00244
how to do this using perl regex.I'm a newbie to perl and would... (1 Reply)
Discussion started by: ramky79
1 Replies
8. Shell Programming and Scripting
How to search string like: a and replace to
a
a
a
:
:
a
in a file with perl?
Thanks,
Grace (6 Replies)
Discussion started by: jinsh
6 Replies
9. Shell Programming and Scripting
Hello friends,
I want to remove 3 header lines and 4 trailer lines,
I am using following , is it correct ?
sed '1,3d';'4,$ d' filename (9 Replies)
Discussion started by: ganesh123
9 Replies