($dialstatus=&quot;ANSWER&quot;) replace with $dialstatus eq &quot;ANSWER&quot;<br>
<br>
perl treats = as an assignment operator. For comparison, you&nbsp; need eq or == .<br>
<br>
-apu<br>
&nbsp;<br><br><div><span class="gmail_quote">On 12/18/05, <b class="gmail_sendername">Code Lover</b> &lt;<a href="mailto:lateef.np@gmail.com">lateef.np@gmail.com</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi all,<br><br>I wanted to execute one of mySQL query when the call is answered i<br>tried with the following code but it dones not seems to work.<br><br>$AGI-&gt;exec('Dial', $dialext);<br><br>my $dialstatus =&nbsp;&nbsp;$AGI-&gt;get_variable(&quot;DIALSTATUS&quot;);
<br>if($dialstatus=&quot;ANSWER&quot;){$Accounting_update-&gt;execute($fdatetime,$Cuniq,$UserName,$CalledN);}<br><br>It is not updating my query when the call is successfull answered, and<br>i checked my query from outside using perl commond it is working well
<br>without any issue.<br><br><br><br><br>--<br>Thank You,<br>Code Lover<br>_______________________________________________<br>--Bandwidth and Colocation provided by <a href="http://Easynews.com">Easynews.com</a> --<br><br>
Asterisk-Users mailing list<br>To UNSUBSCRIBE or update options visit:<br>&nbsp;&nbsp; <a href="http://lists.digium.com/mailman/listinfo/asterisk-users">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br></blockquote></div>
<br>