10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Dear All.
I have a script, which process files one by one. In the script I have two functions.
one sftp files to different server
the other from existing file create file with different name.
My question is:
Will sftp function recognize files names , which are created in another... (1 Reply)
Discussion started by: digioleg54
1 Replies
2. Shell Programming and Scripting
Hi,
I've come accross a situation where I need to exit from current shell script at the same time I need to start/activate another shell script.
How can I do that in KSH ?? Need help !!
For example, my script is as below
#!/bin/ksh
paramFile="/home/someXfile.lst"
] && <<Here I... (1 Reply)
Discussion started by: R0H0N
1 Replies
3. Shell Programming and Scripting
Hi
I have been using sed -n -e '/regex/{N;p;}' to print the matching line and the next line.
In cases where I have a matching line at the end of the document with no next line, that line is skipped. How do I print that line as well?
Thanks. (10 Replies)
Discussion started by: jamie_123
10 Replies
4. Shell Programming and Scripting
Hi,
i have a script a.sh that calls b.sh
Both take parameters
a.sh
{
b.sh p1 p2 p3
}
b.sh
{
GIVEN_CMD="`basename $0` $@"
echo "${GIVEN_CMD}
}
Now when i run:
a.sh q1 q2
It prints only
a.sh q1 q2
Inside b.sh, how can i print both the script names and their parameters passed? (6 Replies)
Discussion started by: ysrini
6 Replies
5. UNIX for Dummies Questions & Answers
Hi everyone,
Is there a slick way to determine the FULL name of a script that is running?
The variable ${0} just gives the relative path name.
I guess I could just do the following:
FULL_SCRIPT_NAME=${PWD}${0}Although that's pretty simple is there another way that I am missing?
... (4 Replies)
Discussion started by: msb65
4 Replies
6. Shell Programming and Scripting
This is my function which is creating three variables based on counter & writing these variable to database by calling another function writeRecord
but only one record is getting wrote in DB.... Please advise ASAP...:confused:
function InsertFtg
{
FTGSTR=""
echo "Saurabh is GREAT $#"
let... (2 Replies)
Discussion started by: omkar.sonawane
2 Replies
7. Shell Programming and Scripting
Hi,
Using AIX 5.3 and Ksh.
/>ls -al /usr/bin/ksh
-r-xr-xr-x 5 bin bin 237420 Apr 10 2007 /usr/bin/ksh
/>
I recently started working for a new employer. I have written UNIX K-Shell scripts for many years and have never had this particular issue before. Its perplexing me.
I have... (2 Replies)
Discussion started by: troym72
2 Replies
8. Shell Programming and Scripting
Hello all,
I'm new to shell programming and need some help. I would like to set up a step within a shell script to trigger another shell script to run, based on the highest return code generated in the current script. For example, if the highes return code value in the current script is less... (1 Reply)
Discussion started by: mmignot
1 Replies
9. Shell Programming and Scripting
How do i run a shell script or perl script with in the context of a current shell.
I know that i can use command source. but we can't pass any arguments to
our script if we use source command as it takes only one argement i.e filename
Is there any way to run a script in the current shell... (5 Replies)
Discussion started by: Naresh Kumar
5 Replies
10. Shell Programming and Scripting
How can I add to the current oraenv.sh so that is an oracle_sid is passed then it won't prompt for the vaid sid and just take it. If it is not passed then do what it is doing right now ??
if # Command executed from a terminal
then
ORACLE_SID=""
... (1 Reply)
Discussion started by: uuser
1 Replies