09-18-2006
Thank you. I appreciate your help. It's working.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello everyone
I was asked to pass a parameter in the calling of a script. IŽll have two parameters London and Birmingham and IŽll need to pass this because each of these will have a specific script however with the same name.
/home/script/loaddata.ksh Lond
/home/script/loaddata.ksh Birm... (2 Replies)
Discussion started by: Rafael.Buria
2 Replies
2. UNIX for Advanced & Expert Users
Hi all,
I need to write a unix script in which need to call a url.
Then need to pass parameters to that url.
please help.
Regards,
gander_ss (1 Reply)
Discussion started by: gander_ss
1 Replies
3. Shell Programming and Scripting
Hi all,
I need to write a unix script in which need to call a url.
Then need to pass parameters to that url.
please help.
Regards,
gander_ss (1 Reply)
Discussion started by: gander_ss
1 Replies
4. Shell Programming and Scripting
How do i get the value of the variable from the called script(script2) to the calling script(script1) in ksh ?
I've given portion of the script here to explain the problem.
Portion of Script 1
=============
-----
-----
tmp=`a.ksh p1 p2 p3`
if then
# error processing
fi
-----... (10 Replies)
Discussion started by: rajarkumar
10 Replies
5. Shell Programming and Scripting
Hi All,
I tried looking for this, but was not able to get a clear answer. Hence posting here. Please find the details below. Thanks for the help
I have 2 shell scripts, script1.sh and script2.sh. I call script2.sh from within script1.sh ( by simple ./script2.sh command).
Based on some... (7 Replies)
Discussion started by: harimac
7 Replies
6. Shell Programming and Scripting
#!/bin/ksh
row=`sed '1!G;h;$!d' file1.xml | head -2| tail -1`
echo "$row" | awk -F"" '{$esum=$5}'
row=`sed '1!G;h;$!d' file2.xml | head -2| tail -1`
echo "$row" | awk -F"" '{$isum=$5+$19}'
echo "Exp:$esnum"
echo "Imp:$isum"
if
then
echo "Matched"
else
echo "Not matched"
fi
... (6 Replies)
Discussion started by: skyineyes
6 Replies
7. Shell Programming and Scripting
Hi Friends,
I'm calling 'sed' command inside one perl script, which is to list directory names which are having some date value as their names (in the form YYYYMMDD) with in the range (start and end date).
#!/usr/bin/perl -w
use strict;
use warnings;
my $DATA = "/export/home/ganapa";
my... (5 Replies)
Discussion started by: ganapati
5 Replies
8. Programming
gcc is giving me an error when calling exit(-1) in xbuplot.c
cd ../pltlib; make xbuplot.o
make: Entering directory `/media/ios120/chrisd/research/fast-zb/fast/pltlib'
gcc -c -o xbuplot.o xbuplot.c
xbuplot.c: In function xbuinit_':
xbuplot.c:171:5: warning: incompatible implicit... (5 Replies)
Discussion started by: kristinu
5 Replies
9. Shell Programming and Scripting
#!/usr/local/bin/bash
set -vx
/prod/HotelierLinks/palaceLink/bin/PalacefilesWait /prod/HotelierLinks/palaceLink/bin/prodEnvSetup 03212013 &
if
then
echo "fatal error: Palace/HardRock failed!!!!" 1>&2
echo "Palace Failed" | mail -s "Link Failed at Palace/HardRock" -c... (1 Reply)
Discussion started by: aroragaurav.84
1 Replies
10. Shell Programming and Scripting
hi,
i want to pop up an alert box using perl script. my requirement is.
i am using a html page which calls a perl script. this perl script calls a shell script.. after the shell script ends its execution, i am using exit 0 to terminate the shell script successfully and exit 1 to terminate the... (3 Replies)
Discussion started by: Little
3 Replies
exit(1) User Commands exit(1)
NAME
exit, return, goto - shell built-in functions to enable the execution of the shell to advance beyond its sequence of steps
SYNOPSIS
sh
exit [n]
return [n]
csh
exit [ ( expr )]
goto label
ksh
*exit [n]
*return [n]
DESCRIPTION
sh
exit will cause the calling shell or shell script to exit with the exit status specified by n. If n is omitted the exit status is that of
the last command executed (an EOF will also cause the shell to exit.)
return causes a function to exit with the return value specified by n. If n is omitted, the return status is that of the last command exe-
cuted.
csh
exit will cause the calling shell or shell script to exit, either with the value of the status variable or with the value specified by the
expression expr.
The goto built-in uses a specified label as a search string amongst commands. The shell rewinds its input as much as possible and searches
for a line of the form label: possibly preceded by space or tab characters. Execution continues after the indicated line. It is an error to
jump to a label that occurs between a while or for built-in command and its corresponding end.
ksh
exit will cause the calling shell or shell script to exit with the exit status specified by n. The value will be the least significant 8
bits of the specified status. If n is omitted then the exit status is that of the last command executed. When exit occurs when executing
a trap, the last command refers to the command that executed before the trap was invoked. An end-of-file will also cause the shell to exit
except for a shell which has the ignoreeof option (See set below) turned on.
return causes a shell function or '.' script to return to the invoking script with the return status specified by n. The value will be the
least significant 8 bits of the specified status. If n is omitted then the return status is that of the last command executed. If return
is invoked while not in a function or a '.' script, then it is the same as an exit.
On this man page, ksh(1) commands that are preceded by one or two * (asterisks) are treated specially in the following ways:
1. Variable assignment lists preceding the command remain in effect when the command completes.
2. I/O redirections are processed after variable assignments.
3. Errors cause a script that contains them to abort.
4. Words, following a command preceded by ** that are in the format of a variable assignment, are expanded with the same rules as a vari-
able assignment. This means that tilde substitution is performed after the = sign and word splitting and file name generation are not
performed.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
|Availability |SUNWcsu |
+-----------------------------+-----------------------------+
SEE ALSO
break(1), csh(1), ksh(1), sh(1), attributes(5)
SunOS 5.10 15 Apr 1994 exit(1)