<div dir="ltr">Hi,<div style>I define some values using the varset parameters of cfgutils module.</div><div style>modparam(&quot;cfgutils&quot;, &quot;varset&quot;, &quot;media1=1.2.3.4&quot;)</div><div style>modparam(&quot;cfgutils&quot;, &quot;varset&quot;, &quot;media2=4.3.2.1&quot;)<br>
</div><div style>modparam(&quot;cfgutils&quot;, &quot;varset&quot;, &quot;media3=5.6.7.8&quot;)<br></div><div style><br></div><div style>I need a logic to dynamically select the the variables. Say for example:</div><div style>
I select a value from DB and store it in an AVP say $avp(db_val) which I know can be either 1,2 or 3. Based on that value, I need to select among variables media1, media2 or media3.</div><div style>I need to find a way where I can substitute the avp(db_val) value in the name of the variable. Basically something like this:</div>
<div style>$avp(variable_to_be_used) = $var(media$avp(db_val))</div><div style>So here if $avp(db_val) is 1, avp(variable_to_be_used) becomes $var(media1) which will be 1.2.3.4</div><div style><br></div><div style>Is something like this possible or allowed? Is there an alternative to do something similar dynamically !! I know, I cud have stored those values in DB and retrieved directly but I am looking at this feature for many other purposes too !!</div>
<div style><br></div><div style>Any help is much appreciated. Thanks,</div><div style><br></div><div style>--- Jayesh</div></div>