I have written the below PERL script to reprocess messages from a failure queue.
It basically browses all the messages in the failure queue to individual files in a directory and then scans those files to determine the originating queue. The script will then move each message in turn from...
Hi,
I have a sub function called pressEnter within my perl menu script which basically means that the script will await an interaction from the user before moving on.
Unfortunately when the script goes into pressEnter it just hangs (even if you press enter!!).
Any ideas on what could...
Hi,
I have the below script that should take the command line option and run the desired script on another server. Only it doesn't seem to run the function, infact it just returns back to the command line.
case $1 in
1) msgbacklog() ;;
2) jobstatus() ;;
esac...
Hi,
I have a PERL script which executes a script which interrogates a database on another server and produces an output file (an example of this is at the bottom). Of this file I only want a section of the data, from USER until the last number. I have written the code below but when run it...
Hi,
I'm trying to wrtie a menu perl script which will allow users to connect to different servers from a management server without having to know the long server name.
I have written the below code, but when I execute it I manage to get through the first 2 menus but it doesn't exit once...
Hi,
I'm trying to select a substring within a column but using another string as the starting point. This is because the position of the string in the column may change.
i.e.
select substr(<column name>,<reference string>,3) from table;
ABCDEFGHIJKLMNOPMSGNO123ABCDEFGHIJKL
The refence...
Just a quick question.
What is the difference between executing a script command
using
./usr/local/blah/blah/blah.ksh
and
/usr/local/blah/blah/blah.ksh
Thanks
Chris
Morning,
i'm currently having trouble when passing a value into a variable from another file. I am currently using the below example:
function Command
{
for command in `cat proclst.tmp`
do
set $command
exec $command
done
}
The line I am trying to pass has a space delimiter (and is...
Afternoon all,
Trying to run an IF statement within a script in KSH. Basically I want it to check whether a variable has a value set or whether it is blank.
I currently have the below, but needless to say it's not working. Can anyone spot where i'm going wrong?
If [ $FILE != '' ]
then...
Hi guys,
Just got the attached script to run, which basically sends an email to a recipitent when an error occurs, and unfortunately the output contains a space as below. Any ideas?
Database reconciliation between Tandem and Unix has failed.
Please see the attached file(s).
You can...
When using a While flow, using an argument of count, the value of the variable $count is not incrementing but instead just displaying an output of 1+1+1....
i.e.
Script:
while
[ $count -lt 10 ]
do
echo "$count"
count=`expr $count+1`
done
Output:
+ [ 1 -lt 10 ]
+ echo 1
1
+ + expr 1+1...
Bit of a no brainer probably for most, but i'm banging my head against me monitor at this precise moment in time.
Basically I want to check that the User, is the correct User to run this script against a number of parameters.
i.e.
{
if
[ "env"= "a" ] && [ "node" = "test" ] && [ "User"...
Hi,
I'm having trouble with a script that i'm writing. Basically i'm trying to get my script to check a pre set variable in an IF statement and based on it's value follow a course of action.
i.e.
Variable $node is equal to "trial"
if
$node=trial
then
env=e
else
echo "This environment is...
I am currently writing a script where it is necessary to copy a number of files to a number of directories and I want to do it re-using 1 if statement, what I don't want is to copy all of the files to all the directories.
Basically I want the script to look at the first variable (being the...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.