[Freeswitch-users] mod_odbc_query in dialplan no results
Ximo Peral
ximop_22 at hotmail.com
Wed Sep 2 18:57:10 MSD 2015
Solved! I'm an idiot, the user_name does not exist. Was convinced existed. Sorry for the inconvenience! :S
From: ximop_22 at hotmail.com
To: freeswitch-users at lists.freeswitch.org
Date: Wed, 2 Sep 2015 16:38:47 +0200
Subject: Re: [Freeswitch-users] mod_odbc_query in dialplan no results
Sorry, correction:
The variable "${control}" is not defined, but if I write directly user_name works.
From: ximop_22 at hotmail.com
To: freeswitch-users at lists.freeswitch.org
Date: Wed, 2 Sep 2015 16:28:44 +0200
Subject: [Freeswitch-users] mod_odbc_query in dialplan no results
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?
_________________________________________________________________________
Professional FreeSWITCH Consulting Services:
consulting at freeswitch.org
http://www.freeswitchsolutions.com
Official FreeSWITCH Sites
http://www.freeswitch.org
http://confluence.freeswitch.org
http://www.cluecon.com
FreeSWITCH-users mailing list
FreeSWITCH-users at lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_________________________________________________________________________
Professional FreeSWITCH Consulting Services:
consulting at freeswitch.org
http://www.freeswitchsolutions.com
Official FreeSWITCH Sites
http://www.freeswitch.org
http://confluence.freeswitch.org
http://www.cluecon.com
FreeSWITCH-users mailing list
FreeSWITCH-users at lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20150902/e8159ef9/attachment.html
Join us at ClueCon 2016 Aug 8-12, 2016
More information about the FreeSWITCH-users
mailing list