Hi Mahesh,

the "re" operator accepts only string values as a second operand. See:
   http://www.voice-sistem.ro/docs/avpops/ar01s06.html#avp_check

the limitation is because performance reasons - having dynamic regexp is something very costly. You may consider as alternative the "fm" operator.

regards,
bogdan

Mahesh Paolini-Subramanya wrote:

I think I'm missing something pretty obvious here, but is there a reason that
avp_check("$avp(tmpVar1)", "re/$avp(myNetwork0)/i")
barfs on 1.1.x?

I get the error
 0(0) ERROR:avpops:fixup_check_avp: regexp operation requires string value
 0(0) ERROR: fix_actions: fixing failed (code=-1) at cfg line 3491

In the above,
   $avp(tmpVar1) ==  "1.2.3.4"
   $avp(myNetwork0) == "1.2.3"

Now, I'd hoped that I could actually run the following
avp_check("$avp(tmpVar1)", "re/^$avp(myNetwork0)/i")
but that doesn't work

Then, setting
$avp(myNetwork0) == "^1.2.3"
and running
avp_check("$avp(tmpVar1)", "re/$avp(myNetwork0)/i")
didn't work either

Sooo, whats the solution?
avp_check can't have AVPs on both sides of the check?

cheers
--
*******************************************
Mahesh Paolini-Subramanya      (703) 386-1500 x9100
CTO                                         [EMAIL PROTECTED]
Aptela, Inc.                               http://www.aptela.com
"Aptela: How Business Answers The Call"
*******************************************

------------------------------------------------------------------------

_______________________________________________
Users mailing list
[email protected]
http://openser.org/cgi-bin/mailman/listinfo/users


_______________________________________________
Users mailing list
[email protected]
http://openser.org/cgi-bin/mailman/listinfo/users

Reply via email to