Re: script question
Bob.Kelley_at_BRINKSINC.COM
Date: 02/10/04
- Previous message: JOSEPH KREMBLAS: "Re: script question"
- Maybe in reply to: Bob.Kelley_at_BRINKSINC.COM: "script question"
- Next in thread: JOSEPH KREMBLAS: "Re: script question"
- Reply: JOSEPH KREMBLAS: "Re: script question"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Tue, 10 Feb 2004 11:19:34 -0600 To: aix-l@Princeton.EDU
Thks for the response Bill, maybe I'm missing something here:
export count=1
export redo_1=/tmp
export variable_test=${redo_}${count}
echo $variable_test
Yields "1"
Whats wrong with my syntax?
Bobby Kelley Jr.
972-877-5341
|---------+---------------------------->
| | Bill Verzal |
| | <BVerzal@KOMATSUN|
| | A.COM> |
| | Sent by: IBM AIX |
| | Discussion List |
| | <aix-l@Princeton.|
| | EDU> |
| | |
| | |
| | 02/10/2004 10:40 |
| | AM |
| | Please respond to|
| | IBM AIX |
| | Discussion List |
| | |
|---------+---------------------------->
>--------------------------------------------------------------------------------------------------------------------------------------------------|
| |
| To: aix-l@Princeton.EDU |
| cc: |
| Subject: Re: script question |
>--------------------------------------------------------------------------------------------------------------------------------------------------|
${REDO_MP_TO}_${DB_COUNT}
--------------------------------------------------------
"If everything is coming your way, then you are in the wrong lane"
Bill Verzal
AIX Administrator, Komatsu America
(847) 970-3726 - direct
(847) 970-4184 - fax
Bob.Kelley@BRINKS
INC.COM
Sent by: IBM AIX To
Discussion List aix-l@Princeton.EDU
<aix-l@Princeton. cc
EDU>
Subject
script question
02/10/2004 10:26
AM
Please respond to
IBM AIX
Discussion List
<aix-l@Princeton.
EDU>
I have two variables which are holding spots for mount points.
for i in 1 2
do
export xx=DB$DB_COUNT=$i
export REDO_MP_TO_$DB_COUNT=/apps/"$i"
done
Now I want to use them with commands and such
EG.
...
for i in 1 2
do
cd $REDO_MP_TO_$DB_COUNT
done
but this fails to evaluate correctly in the second loop. How do I get the
$REDO_MP_TO_$DB_COUNT to be recognized as "/apps/1" and "/apps/2" for input
to the cd command?
Bobby Kelley Jr.
972-877-5341
NOTICE TO BRINK'S EMPLOYEES:
All electronic mail communications composed, sent, received or stored on or
through Brink's equipment are subject to the Brink's Electronic
Communications Policy. Employees should have no expectation of privacy in
their use of the Company's electronic mail system.
- Previous message: JOSEPH KREMBLAS: "Re: script question"
- Maybe in reply to: Bob.Kelley_at_BRINKSINC.COM: "script question"
- Next in thread: JOSEPH KREMBLAS: "Re: script question"
- Reply: JOSEPH KREMBLAS: "Re: script question"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|