Hi Jayesh,
have you tried to do directly:
modparam("acc", "db_extra_bye", "sip_dlg_end_reason=$DLG_end_reason")
Regards,
Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
http://www.opensips-solutions.com
On 23.08.2014 14:25, Jayesh Nambiar wrote:
Hello,
How do you insert the $DLG_end_reason in a particular column in acc
table?? I basically did set a db_extra_bye modparam as follows:
modparam("acc", "db_extra_bye", "sip_dlg_end_reason=$avp(dlg_end_reason)")
The problem is; when I do this before the loose route:
if(is_method("BYE")) {
$avp(dlg_end_reason) = $DLG_end_reason
xlog("L_INFO", "Dialog End Reason is $avp(dlg_end_reason)");
}
The $DLG_end_reason returns NULL, since the dialog is not ended yet.
And if I do the same after loose route, the xlog shows up proper
dialog end reason but the same is not inserted into the DB since once
the transaction enters into loose route and probably it cannot set the
values for cdr.
So I am in kind of a deadlock here. Is there a solution to this??
Thanks in advance,
--- Jayesh
_______________________________________________
Users mailing list
[email protected]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
_______________________________________________
Users mailing list
[email protected]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users