10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi
I am trying to understand a shell scipt file ( .ksh file ) . In the shell script we are referring a variable .
Example : SessLogs=$STAFF_MSTR_DIR/staff_dtls
There are no references in the shell script from where the variable "$STAFF_MSTR_DIR" is being read from .
Could anyone... (2 Replies)
Discussion started by: Sudheer Maddula
2 Replies
2. Shell Programming and Scripting
Hi, I have a problem with awk array when iam trying to use awk in solaris box as below..Iam unable to figure out the problem..
Need your help. is there any alternative to make it in arrays from variable values
nawk 'BEGIN {SUBSEP=" ";
split("101880|110045 101887|110045 101896|110045... (9 Replies)
Discussion started by: cskumar
9 Replies
3. Shell Programming and Scripting
I want to pass this array as a parameter.
IFS=$'\n'
fortune_lines=($(fortune | fold -w 30 ))
Inside of this line
screen -p 0 -S ${SCREEN_SESSION} -X stuff "`printf "say ${fortune_lines}\r"`"
And I am lost at this point.
I am thinking something like this?
Then make it loop..
... (7 Replies)
Discussion started by: briandanielz
7 Replies
4. Shell Programming and Scripting
Hello,
I am running a bash script under linux which first defines an CA-array like
j=0
num1=120.00
num2=10.00
until
do
CA='echo $num1 + $j*$num2'
j=$
done
within the later awk section of this same script I want to read data from a file. If the value of the second column is... (3 Replies)
Discussion started by: MotAah
3 Replies
5. Shell Programming and Scripting
Hello again :)
Am currently trying to write a function which will delete a record from a file.
The code currently looks as such:
function deleteRecord() {
clear
read -p "Please enter the ID of the record you wish to remove: " strID
... (2 Replies)
Discussion started by: U_C_Dispatj
2 Replies
6. Shell Programming and Scripting
HI all,
I have a parameter file with entries like
$$Name =Abhinav
$$CUTOFF_DATE = 11/11/2209
I am reading a variable from this file using a awk command like :
var2=`awk -F"" "/CUTOFF_DATE/{f=$1;}{print f;}" InputFIleName`
but facing an error like
awk: cmd. line:1:... (3 Replies)
Discussion started by: abhinav192
3 Replies
7. Shell Programming and Scripting
In a ksh shell... I need to pass 12 parameters to a secondary ksh shell. In VB I would just pass an array that contains all of these, but haven't been successful in passing the full array in a KSH shell.
Does anyone have an example where you can pass an array as a parameter?
here's what i... (3 Replies)
Discussion started by: heyindy06
3 Replies
8. Shell Programming and Scripting
Hi,
I have a parameter file and it contains following items
$ cat TransactionParams
From_Date_Parm=2005-02-25
To_Date_Parm=2005-05-25
Extract_Root_Parm=/detld1/etl/ascential/Ascential/DataStage/Projects/CTI_London/IAM
Extract_Type_Parm=Transaction
EDW_Database_Parm=hdw_erks... (2 Replies)
Discussion started by: gopskrish
2 Replies
9. Shell Programming and Scripting
Hello All,
I have a script that will email out if the email address is specified as parameter 1.
I am using ksh, and then tried the following :
email=$1
Following did not work, I am getting error
test -z $email
test ${email:=" ") -eq " "
test -n $email
test ${?email}
What... (4 Replies)
Discussion started by: negixx
4 Replies
10. UNIX for Dummies Questions & Answers
Can I pass and array as a function paramter?
#!/bin/bash
a1=one
a1=two
a2=one
a2=two
function f1()
{
array1copy=( ${1} )
array2copy=( ${2} )
echo "${array1copy}"
echo "${array2copy}"
}
f1 "${a1}" "${a2}" (2 Replies)
Discussion started by: newbreed1
2 Replies