<div dir="ltr"><div><div>Hello,<br></div>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:<br>modparam(&quot;acc&quot;, &quot;db_extra_bye&quot;, &quot;sip_dlg_end_reason=$avp(dlg_end_reason)&quot;)<br>
<br></div><div>The problem is; when I do this before the loose route:<br><br></div><div>if(is_method(&quot;BYE&quot;)) {<br></div><div>   $avp(dlg_end_reason) = $DLG_end_reason<br></div><div>   xlog(&quot;L_INFO&quot;, &quot;Dialog End Reason is $avp(dlg_end_reason)&quot;);<br>
</div><div>}<br><br></div><div>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.<br>
</div><div>So I am in kind of a deadlock here. Is there a solution to this??<br><br>Thanks in advance,<br><br></div><div>--- Jayesh<br></div></div>