10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I am a bit confused ,why would a sed command work fine outside of ksh script but not inside.
e.g
I want to replace all the characters which end with a value and have space at end of it.
so my command for it is :
sed -i "s/$SEPARATOR /$SEPARATOR/g" file_name
This is working fine in... (8 Replies)
Discussion started by: vital_parsley
8 Replies
2. Shell Programming and Scripting
We are migrating some scripts (ksh) from Solaris 10 to Linux 2.6.32.
Can someone share list of changes i need to take care for this ?
Have found few of them but i am looking for a exhaustive list.
Thanks. (6 Replies)
Discussion started by: Shivdatta
6 Replies
3. Shell Programming and Scripting
Hello Friends,
I have written a code on a Linux box, however, am getting issues while running it on a Solaris server. The issue with Sed command is sortd out, however, am still lokking for solutions with expr command. Here is the issue,
Linux :
bash-2.03$ expr match singh@test.com... (10 Replies)
Discussion started by: suffisandy
10 Replies
4. Shell Programming and Scripting
Hi all,
I'm trying to run an sql inside a loop which looks like this
#!bin/ksh
while IFS=, read var1 var2
do
sqlplus -s ${USERNAME}/${PASSWORD}@${ORACLE_SID} << EOF
insert into ${TABLE}
(
appt_date
)
values
(
'${var1 }'
);
... (6 Replies)
Discussion started by: ryukishin_17
6 Replies
5. Shell Programming and Scripting
hi guys,
my ksh script is calling another script. The other script expects user to press CNTR-C, and does not return to the prompt.
in my script, I want to call the other script, but somehow don't want it to wait forever, I want to return to my script.
e.g.
script2.ksh outputs:
"No... (2 Replies)
Discussion started by: JamesByars
2 Replies
6. Shell Programming and Scripting
Hi ALL,
i am so much confused y the following script is not working in the korn shel which works in bash shell. please solve the error that i am facing.
i want to extract the format of the size from a variable i.e. GB or KB or MB or B or BYTES
code:
--------
size_dir_pass=1.2gb... (2 Replies)
Discussion started by: G.K.K
2 Replies
7. Shell Programming and Scripting
Within a ksh script on HP-UX I trying to calculate a percentage of a number (number/100 x percentage) using the below method and expr.
TARPERC=`expr 16 / 100 \* 5`
TARSUM=`expr 16 + $TARPERC`
ZIPSUM=`expr $TARSUM \* 2`
If the input is 16
outputs are:
TARPERC: 0
TARSUM: 16
ZIPSUM: 32... (6 Replies)
Discussion started by: wurzul
6 Replies
8. Solaris
Hi ,
I have a shell script to perform some actions on sun solaris box . This script normally requires to be run as a different user. so, whenever i have to run this script, i need to sudo in as that user , enter the password and execute it. Now,I have to setup a cronjob to execute the script... (11 Replies)
Discussion started by: csg_user
11 Replies
9. UNIX for Advanced & Expert Users
I cannot seem to get this text file to format. Its as if the awk statement is being treated as a simple cat command.
I manned awk and it was very confusing. I viewed previous posts on this board and I got the same results as with the
the awk command statement shown here. Please help.
... (6 Replies)
Discussion started by: tekline
6 Replies
10. UNIX for Advanced & Expert Users
Hi,
I have written a korn shell script to compute the value of k.
formulae :
a=10
b=20
c=30
k=(a+b)*c
my shell script is :
a=10
b=20
c=30
k=`expr (($a + $b ) * $c )`
echo $k
### here paranthesis ( ) not accepting by expr function. (3 Replies)
Discussion started by: krishna
3 Replies