04-13-2009
Hi Vgersh,
Thank you very much.....I solved the problem....its because of ' when invoked in program so I replaced ' with ''. Now its working fine. Tks for ur tip and trick.....
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Does anyone know how to insert text at the top and bottom of a file using sed? (12 Replies)
Discussion started by: MBGPS
12 Replies
2. Shell Programming and Scripting
how would you insert text into a existing file using aguments
first arguments being the line of text and the second argument being file name (1 Reply)
Discussion started by: jimbob
1 Replies
3. UNIX for Dummies Questions & Answers
Hi this is quite simple i am sure but without using awk or sed i need to add text to the top of a file this is what i have got so far
#!bin/bash
echo "Add text to top of file"
read line
echo $line >> file1
This adds the text to the bottom of the file can some1 please help cheers (7 Replies)
Discussion started by: meadhere
7 Replies
4. Shell Programming and Scripting
Hi,
I wanted to add specific text to each row in a text file containing three rows. Example:
0 8 7 6 5 5
7 8 9 0 7 9
7 8 9 0 1 2
And I want to add a 21 at the beginning of the first row, and blank spaces at the beginning of the second two rows. To get this:
21 0 8 7 6 5 5
7 8... (4 Replies)
Discussion started by: hertingm
4 Replies
5. UNIX for Dummies Questions & Answers
Dear All,
I have two files
One is script file in which I am writing commands to append a text in a normal file.
I want to insert the text on top of the file.
I dont want to use sed and awk commands nor temp file.
is it possible? (3 Replies)
Discussion started by: anjali
3 Replies
6. Shell Programming and Scripting
Hi All
I am making a script in which.I have a problem i try to discribe.
File1 content need to be append in file 2 but such as if content already exist then dont add.
File1 IS Like this
myname
yourname
hername
hisname
File2
%AddNameHere myname yourname hername hisname (3 Replies)
Discussion started by: aliahsan81
3 Replies
7. Shell Programming and Scripting
I am attempting to insert multiple lines of text into a specific place in a text file based on the lines above or below it.
For example, Here is a portion of a zone file.
IN NS ns1.domain.tld.
IN NS ns2.domain.tld.
IN ... (2 Replies)
Discussion started by: cdn_humbucker
2 Replies
8. Shell Programming and Scripting
Hello,
I after some assistance please. Below is a file I need to read and for each line write an output.
My input file looks like this
2 20008 2003-08-26
2 20032 2003-08-26
2 20041 2003-08-26
2 20037 2003-08-26
2 20050 2003-08-26
6 ... (6 Replies)
Discussion started by: giles.cardew
6 Replies
9. Shell Programming and Scripting
I have a text file that has data like:
Data "12345#22"
Fred
ID 12345
Age 45
Wilma
Dino
Data "123#22"
Tarzan
ID 123
Age 33
Jane
I need to figure out a way of adding 1,000,000 to the specific lines (always same format) in the file, so it becomes:
Data "1012345#22"
Fred
ID... (16 Replies)
Discussion started by: say170
16 Replies
10. Shell Programming and Scripting
If I have a txt file with
test.txt
somelineoftext
and I want to set that line of text to variable in a script:
so
#!/bin/bash
var=''
becomes
#!/bin/bash
var='somelineoftext' (3 Replies)
Discussion started by: digitalviking
3 Replies
phones(4) File Formats phones(4)
NAME
phones - remote host phone number database
SYNOPSIS
/etc/phones
DESCRIPTION
The file /etc/phones contains the system-wide private phone numbers for the tip(1) program. /etc/phones is normally unreadable, and so may
contain privileged information. The format of /etc/phones is a series of lines of the form:
<system-name>[ ]*<phone-number>.
The system name is one of those defined in the remote(4) file and the phone number is constructed from [0123456789-=*%]. The `=' and `*'
characters are indicators to the auto call units to pause and wait for a second dial tone (when going through an exchange). The `=' is
required by the DF02-AC and the `*' is required by the BIZCOMP 1030.
Comment lines are lines containing a `#' sign in the first column of the line.
Only one phone number per line is permitted. However, if more than one line in the file contains the same system name tip(1) will attempt
to dial each one in turn, until it establishes a connection.
FILES
/etc/phones
SEE ALSO
tip(1), remote(4)
SunOS 5.10 14 Jan 1992 phones(4)