Considering the number of views of the thread and that I couldn't find anything in the documentations, I assume there is nothing like that. Meanwhile I just increased a hit-counter variable and check if it is set like:
Hi All,
I have a variable in a shell script which holds let say n paarmeteres with space separate them :
$var = par1 par2 par3 par4 parn;
so if I print this variable this is what I'll see:
par1 par2 par3 par4 parn
I need to insert each parameter to an array , so I can go over on each... (3 Replies)
Hello everybody, I'm new in this forum.
I searched a long time for a solution for my problem but I didn't find the right thing.
I have to read from a file (content is "abngjm" without any other signs) and have to write this content in an array. But every sign has to be called by its own... (5 Replies)
Hi all,
I have this scenario where:-
The file that I want to save its name into array df is my.08120323.trx which is located in the dir as below:
$ pwd
/u01/abc/def/SRC_datafiles
$ ls *trx
my.08120323.trx
$ df=*"trx" ##keeping the filename... (1 Reply)
Experts,
I have a bash shell script that generates 2 variables that have the current minute and a minute from a log file. Can someone please show me the best way to test if the minutes stray by 5. So basically if:
This is ok:
Last Fitting Min
=============
02
Current Minute
=============... (2 Replies)
Hi, as the title, I have an array @f_lines with gene information in it. How can I put the content of @f_lines into a file so that I can read it?
I tried this:
open(OUTPUT, "file"); # put gene information in this file;
@f_lines = ("gene1", "gene2", "gene3"...); # gene information;
print... (3 Replies)
RedHat 5
KSH
I am creating an array, and then using case to go through and count for specific words. Then the count gets stored as an expression.
string='ftp rcp rsh telnet ftp ftp'
set -A myarray $string
FTPCOUNT="0"
for command in ${myarray}
do
case $command in
ftp) FTPCOUNT=`expr... (2 Replies)
Hi folks,
I am self-learning as I can
I have a script that has read a file into an array.
I can read out each line in the array with the code:
for INDEX in {0..$LENGTH} ## $LENGTH was determined at the read in
do
echo "${data}"
done
What I need to do is test the first char... (2 Replies)
Good afternoon,
I am tearing hair out over this. It should be so simple. I have an if statement to evaluate whether or not replication is working. I am testing variables from mysql to see if they are both "Yes". I have put some echo statements in to see how far the code proceeds. It always... (6 Replies)
Ya, I know, who in this day and age is mirroring rootvg...?
But yes, my shop does and I need to script checking for it.
I also know I could just inverse the the logic and call the LV mirrored
if the LPs and PPs were not equal. But I want to do the math in the if test
and also know I could... (5 Replies)