[OpenSIPS-Users] dp_translate with $avp(s:xyz) not working

Sergio Gutierrez saguti at gmail.com
Thu May 28 14:55:03 CEST 2009


Hi Uwe.

I faced a similar problem; what I tried was applying a transformation on the
AVP and assign it to another AVP:

$avp(i:10)=$(avp(s:billing){s.int});

and then, use $avp(i:10) for dp_translate.

Regards.

Sergio.

On Thu, May 28, 2009 at 6:26 AM, Uwe Kastens <kiste at kiste.org> wrote:

> Hi,
>
> If I call dp_translate with an integer, everything is working as expected:
>
> if (!dp_translate("12345", "$fU/$avp(s:service)")) {
>
> If I try the same with an AVP, I will get the following error:
>
> xlog (" billingid $avp(s:billing)");
> if (!dp_translate("$avp(s:billing)", "$fU/$avp(s:service)")) {
>
> May 28 13:20:21 osip /usr/sbin/opensips[13676]:  billingid 12345
> May 28 13:20:21 osip /usr/sbin/opensips[13676]:
> DBG:dialplan:dp_get_ivalue: searching 4
> May 28 13:20:21 osip /usr/sbin/opensips[13676]:
> ERROR:dialplan:dp_get_ivalue: no AVP or SCRIPTVAR found (error in scripts)
> May 28 13:20:21 osip /usr/sbin/opensips[13676]:
> ERROR:dialplan:dp_translate_f: n
> o dpid value
>
> Any hints?
>
> BR
>
> Uwe
>
>
>
> --
>
> kiste lat: 54.322684, lon: 10.13586
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>



-- 
Sergio Gutiérrez
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.opensips.org/pipermail/users/attachments/20090528/fee5d1c9/attachment.htm 


More information about the Users mailing list