[OpenSIPS-Users] insert dialog end reason into DB
Jayesh Nambiar
jayesh1017 at gmail.com
Sat Aug 23 13:25:10 CEST 2014
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
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20140823/dffc8556/attachment.htm>
More information about the Users
mailing list