<html><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:12pt"><div class="" style="">Dear all.</div><div class="" style=""><br class="" style=""></div><div style="background-color: transparent;" class="">I am trying to use the both modules, but i have problems:</div><div style="background-color: transparent;" class=""><br class="" style=""></div><div style="background-color: transparent; color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal;" class="">Always the balance decreases and when i cancel the call the destination number ringing anyway.</div><div style="background-color: transparent;" class=""><span style="background-color: transparent; font-size: 12pt;" class="">Also if the customer does not have balance, to try to make a call this goes
 smoothly</span></div><div style="background-color: transparent; color: rgb(0, 0, 0); font-size: 12pt; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal;" class=""><span style="background-color: transparent; font-size: 12pt;" class="">in other words the calls always comes.&nbsp;</span><br class="" style=""></div><div style="background-color: transparent; color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal;" class=""><br class="" style=""></div><div style="background-color: transparent; color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal;" class="">The log&nbsp;<a href="http://pastebin.freeswitch.org/23267" style="font-size: 12pt;" class="">http://pastebin.freeswitch.org/23267</a></div><div
 style="background-color: transparent; color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal;" class=""><br class="" style=""></div><div style="background-color: transparent; color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal;" class="">My lcr.conf.xml</div><div style="background-color: transparent; color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal;" class=""><br class="" style=""></div><div style="background-color: transparent;" class="">&lt;configuration name="lcr.conf" description="LCR Configuration"&gt;</div><div style="background-color: transparent;" class="">&nbsp; &lt;settings&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp;
 &lt;!--&lt;param name="odbc-dsn" value="freeswitch-mysql:freeswitch:Fr33Sw1tch"/&gt;--&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &lt;param name="odbc-dsn" value="freeswitch:freeswitch:vmo123"/&gt;</div><div style="background-color: transparent;" class="">&nbsp; &lt;/settings&gt;</div><div style="background-color: transparent;" class="">&nbsp; &lt;profiles&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &lt;profile name="default"&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &lt;param name="id" value="0"/&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &lt;param name="order_by" value="rate,quality,reliability"/&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &lt;/profile&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &lt;profile name="qual_rel"&gt;</div><div
 style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &lt;param name="id" value="1"/&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &lt;param name="order_by" value="quality,reliability"/&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &lt;/profile&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &lt;profile name="rel_qual"&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &lt;param name="id" value="2"/&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &lt;param name="order_by" value="reliability,quality"/&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &lt;/profile&gt;</div><div style="background-color: transparent;" class=""><br class="" style=""></div><div style="background-color: transparent;" class=""><br class="" style=""></div><div
 style="background-color: transparent;" class="">&nbsp; &nbsp; &lt;profile name="pg_prefix2"&gt;</div><div style="background-color: transparent;" class=""><span style="background-color: transparent; font-size: 12pt;" class="">&nbsp; &nbsp; &nbsp; &nbsp; &lt;param name="order_by" value="rate,quality,reliability"/&gt;</span><br class="" style=""></div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &nbsp; &lt;param name="export_fields" value="nibble_account,nibble_rate,lowbal_amt,nobal_amt"/&gt;</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &nbsp; &lt;param name="custom_sql" value="</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &nbsp; SELECT l.digits AS lcr_digits,</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;c.id AS lcr_carrierid_field,</div><div style="background-color: transparent;"
 class="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;c.carrier_name AS lcr_carrier_name,</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;l.${lcr_rate_field} as lcr_rate_field,</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cg.prefix AS lcr_gw_prefix, cg.suffix AS lcr_gw_suffix,</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;l.lead_strip AS lcr_lead_strip, l.trail_strip AS lcr_trail_strip,</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;l.prefix AS lcr_prefix, l.suffix AS lcr_suffix,</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;a.id AS nibble_account,</div><div style="background-color: transparent;" class="">&nbsp;
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;l.${lcr_rate_field} AS nibble_rate,</div><div style="background-color: transparent;" class="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;a.warn_limit AS lowbal_amt,</div><div class="" style=""><div class="" style="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; a.nobal_limit AS nobal_amt,</div><div class="" style="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;a.id_tarifa AS tarifa&nbsp;</div><div class="" style="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; FROM lcr l</div><div class="" style="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; JOIN carriers c ON l.carrier_id=c.id</div><div class="" style="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; JOIN carrier_gateway cg ON c.id=cg.carrier_id</div><div class="" style="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; JOIN auth_user a ON a.id = ${accountcode}&nbsp;</div><div class="" style="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; JOIN tarifas t ON t.id =
 a.id_tarifa&nbsp;</div><div class="" style="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; WHERE c.enabled = '1' AND cg.enabled = '1' AND l.enabled = '1'</div><div class="" style="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; AND l.digits @&gt; '${lcr_query_digits}'</div><div class="" style="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; AND CURRENT_TIMESTAMP BETWEEN date_start AND date_end</div><div class="" style="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ORDER BY digits DESC, ${lcr_rate_field}, random();</div><div class="" style="">&nbsp; &nbsp; &nbsp; "/&gt;</div><div class="" style="">&nbsp; &nbsp; &lt;/profile&gt;&nbsp;</div><div class="" style="">&nbsp;&lt;/profiles&gt;</div><div class="" style="">&lt;/configuration&gt;</div><div class="" style=""><br class="" style=""></div><div class="" style=""><span style="font-size: 12pt;" class="">My Dialplan:</span><br class="" style=""></div><div class="" style=""><br class="" style=""></div><div class="" style=""><div
 class="" style="">&nbsp; &lt;extension name="tests"&gt;</div><div class="" style="">&nbsp; &nbsp; &nbsp; &lt;condition field="destination_number" expression="^([23]\d{3})$"&gt;</div><div class="" style=""><span style="font-size: 12pt;" class="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;action application="lcr" data="$1 pg_prefix2"/&gt;</span><br class="" style=""></div></div><div class="" style=""><div class="" style="">&nbsp; &nbsp; &nbsp; &nbsp;&nbsp;<span style="font-size: 12pt;" class="">&nbsp; &lt;action application="bridge" data="${lcr_auto_route}"/&gt;</span></div><div class="" style=""><div class="" style="">&nbsp; &nbsp; &nbsp; &lt;/condition&gt;</div><div class="" style="">&nbsp; &nbsp; &lt;/extension&gt;</div><div class="" style=""><br class="" style=""></div><div class="" style=""><br class="" style=""></div><div class="" style="">What i doing wrong i am follow&nbsp;<a
 href="http://wiki.freeswitch.org/wiki/Mod_lcr#Integrating_with_mod_nibblebill" style="background-color: rgb(255, 255, 255); font-size: 12pt;" class="">http://wiki.freeswitch.org/wiki/Mod_lcr#Integrating_with_mod_nibblebill</a></div><div class="" style=""> &nbsp;</div><div class="" style="">&nbsp;</div></div><div class="" style="">I appreciate some help.</div><div class="" style=""><br class="" style=""></div><div class="" style="">regards</div></div><div class="" style=""><br class="" style=""></div></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: transparent; font-style: normal;" class="">&nbsp;</div></div></body></html>