Quantcast
Channel: UNIX and Linux Forums
Viewing all articles
Browse latest Browse all 16232

How to get the variable from a variable.?

$
0
0
Contents of runcalc3.msh
Code:

execute calculation $ess_app.$ess_db.zap_data;
I want to get the contents of runcalc3.ksh in a variable in such a way that
I get the value of ess_app and ess_db also which is set in another shell script.

I tried using this in unix

Code:

export test="$(<runcalc3.msh)"
test1=`echo $(echo $test)`
echo $test1

. It does not work.

It gives me
Code:

execute calculation $ess_app.$ess_db.zap_data;
But I want
execute calculation am.bd.zap_data;

where ess_app='am'
ess_db='bd"

Any help will be appreciated.

Kuntal

Viewing all articles
Browse latest Browse all 16232

Latest Images

Trending Articles



Latest Images