<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
BINGO!
<br>My humble thanks!
<p>Chris Cox wrote:
<blockquote TYPE=CITE>In pure Bourne shell...
<p>MOM_CHAIR="Too soft"
<br>POP_CHAIR="Too hard"
<br>KID_CHAIR="Just right"
<br>while read person; do
<br>&nbsp;&nbsp;&nbsp; chair_var="${person}_CHAIR"
<br>&nbsp;&nbsp;&nbsp; eval chair_value=\$${chair_var}
<br>&nbsp;&nbsp;&nbsp; echo "$chair_value"
<br>done
<p>Fred James wrote:
<br>>
<br>> This is Bourne shell scripting.
<br>>
<br>> Given similar environment variables such as
<br>>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MOM_CHAIR
<br>>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; POP_CHAIR
<br>>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; KID_CHAIR
<br>> I want to build the variable name on the fly and retrieve the value
to base a decision
<br>> on in my script.
<br>> Hints?
<br>>
<br>>
<br>> --
<br>> Consider Fractals
<br>> a large, calm, black cat
<br>> who seems often to be my spiritual leader.
<br>>
<br>>
<br>_______________________________________________
<br><a href="http://ntlug.org/mailman/listinfo/discuss">http://ntlug.org/mailman/listinfo/discuss</a></blockquote>

<pre>--&nbsp;
Consider Fractals
a large, calm, black cat
who seems often to be my spiritual leader.</pre>
&nbsp;</html>