10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I have the following challenge at work that I need to write a script for.
I have a file abc.txt with the following contents:
I want to be able to search/replace in abc.txt - the first 4 characters anything starting with 4560 to 7777; 4570... (3 Replies)
Discussion started by: pchang
2. UNIX for Dummies Questions & Answers
I have a shell script where I have to connect t oracle database. I have to store the command in a variable and then run the command through the variable.The OS is solaris 10 and the shell is bash.pls help when I run the command it doesnot work.Thanks.
CONNECT= "sqlplus... (4 Replies)
Discussion started by: Rossdba
3. Shell Programming and Scripting
I have below variable,
Now, if you will run the below command
=> echo $xyz
It is returning hardcoded string value.
Whereas in environment, there is value in it. Like below:
=> echo $AI_XFR
I need to resolve this... (4 Replies)
Discussion started by: adgangwar
4. Shell Programming and Scripting
I need help to store the value returned from the function to one variable and then use that variable.
date '+%m %d %Y' |
read MONTH DAY YEAR
DAY=`expr "$DAY" - 1`
case "$DAY" in
MONTH=`expr "$MONTH" - 1`
case... (1 Reply)
Discussion started by: aroragaurav.84
5. Shell Programming and Scripting
can anyone please help me with this:
i have written a shell script and a stored procedure which has one OUT parameter. now i want to use that out parameter as an input to the unix script but i am getting an error as variable not found. below are the unix scripts and stored procedure...
... (4 Replies)
Discussion started by: swap21783
6. UNIX for Dummies Questions & Answers
So glad I found this forum!
I need to get a list of users in a variable so I can use "for" to iterate through them in a bash script.
I know this does not work, but I need to do something like this:
myusers=(cat /etc/passwd | cut -f1 -d )
for myuser in $myusers
... (2 Replies)
Discussion started by: holocene
7. Shell Programming and Scripting
I have a variable say var1 (output from somewhere, which I can't change)which store something like this:
how can I make the variable $name, $age, $address and $password contain the info?
I mean do this in a... (1 Reply)
Discussion started by: freddy1228
8. Shell Programming and Scripting
I want to write a perl script, which will increment number stored in file. I want to do this without any file handles. I think we have to use some UNIX commands. I am not sure how to do this with file handles.
Thanks, (1 Reply)
Discussion started by: solitare123
9. Shell Programming and Scripting
I want to search for a data type in a line.For this in a loop i am checking for $DATA_TYPE in a line using grep.But grep is not able to find when i give this.
Can any one tell me how to check string in $DATA_TYPE variable in line usign grep (or) any other way to do the above task.
... (4 Replies)
Discussion started by: jisha
10. UNIX for Dummies Questions & Answers
the code i ve written is as follows:
command="egrep ',100,|,200,' | wc -l"
count =`cat trial.txt | $command`
the contents of
trial.txt is :
i need to get the count using the command stored in a variable and using... (2 Replies)
Discussion started by: Syms