[Freeswitch-users] mod_odbc_query in dialplan no results

Ximo Peral ximop_22 at hotmail.com
Wed Sep 2 18:28:44 MSD 2015


I am trying to obtain results of an SQL query, the query is:
<extension name="lookup_the_control" continue="true">      <condition>        <action application="odbc_query" inline="true" data="SELECT CONCAT(caronte,callerid_mal_formado) AS control FROM company WHERE account_number='${user_name}'"/>      </condition>    </extension>
The variable "$ {check}" is not defined, but if I write directly user_name works.
The output is:
Dialplan: sofia/external/965462224 at 78.136.81.1 Action odbc_query(SELECT CONCAT(caronte,callerid_mal_formado) AS control FROM company WHERE account_number='${user_name}') INLINEEXECUTE sofia/external/965462224 at 78.136.81.1 odbc_query(SELECT CONCAT(caronte,callerid_mal_formado) AS control FROM company WHERE account_number='117201')Dialplan: sofia/external/965462224 at 78.136.81.1 ANTI-Action set(control_origen=${control})2015-09-02 16:21:08.046388 [DEBUG] mod_dptools.c:1498 SET sofia/external/965462224 at 78.136.81.1 [control_origen]=[UNDEF]
Any ideas? 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20150902/5ad88a28/attachment.html 


Join us at ClueCon 2016 Aug 8-12, 2016
More information about the FreeSWITCH-users mailing list