<html><head><meta http-equiv="Content-Type" content="text/html charset=iso-8859-1"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Mike:<div><br></div><div>export is your friend.</div><div><br></div><div><div><blockquote type="cite"><div dir="ltr">OK, I am just thoroughly writer's blocked, probably missing something obvious; but who knows.&nbsp; Anyway, here's my question<br><br># node=somenode<br># echo $node<br>somenode<br># somenodeVar=5&nbsp;&nbsp;<i><b> // if this works</b></i><br>
# echo $somenodeVar<br>5<br># $node"Var"=5 <i><b>// why doesn't this work?</b></i><br>bash: somenodeVar=5: command not found<br></div></blockquote><br></div><div><div>[16:06:18 rderoo@daggoo ~]$ node=somenode</div><div>[16:07:03 rderoo@daggoo ~]$ echo $node</div><div>somenode</div><div>[16:07:49 rderoo@daggoo ~]$ export "${node}Var"=5</div><div>[16:07:57 rderoo@daggoo ~]$ echo $somenodeVar;</div><div>5</div><div><div>[16:07:58 rderoo@daggoo ~]$ echo $somenodeVar;</div></div><div><br></div></div><br></div><div>For the time being well skip the discussion on why variable variables are bad and that one should really be using arrays...</div><div><br></div><div>Kind Regards,</div><div>Raymond</div></body></html>