10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello,
I have a relatively large text file (25,000K) consisting of records of data. For each record, I need to create a new line based on what is already there.
Every record has a block that looks like,
M END
> <ID>
1
> <SOURCE>
KEGG
> <SOURCE_ID>
C00002
> <NAME>
ATP;... (4 Replies)
Discussion started by: LMHmedchem
4 Replies
2. Shell Programming and Scripting
I have a big file having 100 K lines.
I have to read each line and see at 356 character position whethere there is a word "W" in it. If it is their then don't delete the line otherwise delete it.
There are two lines as one Header and one trailer which should remain same.
Can somebody... (5 Replies)
Discussion started by: mohit kanoongo
5 Replies
3. UNIX for Dummies Questions & Answers
Dear all,
I have a file with two columns - the first column is increasing every 50, the second column is just count (e.g. 5). However, when count is zero, no line is present.
Sample:
1950 7
2000 14
2050 7
2100 13
2150 10
2200 9
2250 7
2300 8
2350 7... (1 Reply)
Discussion started by: TheTransporter
1 Replies
4. Shell Programming and Scripting
I need some help with adding lines to file and substitute a pattern.
Ok I have a file:
#cat names.txt
name: John Doe
stationed: 1
name: Michael Sweets
stationed: 41
.
.
.
And would like to change it to:
name: John Doe
employed
permanently
stationed: 1-office (7 Replies)
Discussion started by: hemo21
7 Replies
5. Shell Programming and Scripting
Hi all,
I have a positional text file that comes from some source application. Before it is processed by destination application I have to add some header (suffix) to every record(line) in the file.
e.g.
Actual File
...............
AccountDetails
AcNO Name Amount
1234 John 26578
5678... (3 Replies)
Discussion started by: sharath160
3 Replies
6. UNIX for Dummies Questions & Answers
Hi everybody,
I've got two simples file1 like:
aaa aaa aaa
bbb bbb bbb
ccc ccc ccc
and file2 like:
111 111 111
222 222 222
333 333 333
I need to:
1) add a line say "new line" as the first line of the file
2)add a column from file2 (say column3) to file1; the new column should... (14 Replies)
Discussion started by: zajtat
14 Replies
7. Shell Programming and Scripting
Hi all,
I m new to shell programming..Can anyone please guide me how to insert data at a specified location in the file..
I have a configuration file..I want to add data to it through script..I am able to do it...I get that data written at end of my configuration file..I want data to be placed at... (3 Replies)
Discussion started by: divya_flora
3 Replies
8. Shell Programming and Scripting
Hi,
I need to insert two new lines in a file:
The file:
".....
......
ULIMIT_MAX_FILES="ulimit -S -n `ulimit -H -n`"
....
....
"
I need to add the lines:
LD_LIBRARY_PATH='$LD_LIBRARY_PATH:$APACHE_HOME/modules'
DOWNLOADMODULE_CONF_PATHNAME='$APACHE_HOME/conf/DWLModule.cfg'
right... (2 Replies)
Discussion started by: potro
2 Replies
9. Shell Programming and Scripting
Hi There
I have this file that I would like to add entries to, however, there is a "}" as the last line that I need to keep. Basically i would like to know how I can write a script that will add new lines at the second to last line position (ie always add new line above the close bracket)
... (17 Replies)
Discussion started by: hcclnoodles
17 Replies
10. Shell Programming and Scripting
Suppose content of my first file:
first line
second line
third line
How can i insert text between "first line" & "second Iline"
Any help?????/ (7 Replies)
Discussion started by: bishweshwar
7 Replies