<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 12pt;
font-family:Calibri
}
--></style></head>
<body class='hmmessage'><div dir='ltr'><div>I am trying to obtain results of an SQL query, the query is:</div><div><br></div><div><div><i><extension name="lookup_the_control" continue="true"></i></div><div><i> <condition></i></div><div><i> <action application="odbc_query" inline="true" data="SELECT CONCAT(caronte,callerid_mal_formado) AS control FROM company WHERE account_number='${user_name}'"/></i></div><div><i> </condition></i></div><div><i> </extension></i></div></div><div><br></div><div>The variable "$ {check}" is not defined, but if I write directly user_name works.</div><div><br></div><div>The output is:</div><div><br></div><div><div><i>Dialplan: sofia/external/965462224@78.136.81.1 Action odbc_query(SELECT CONCAT(caronte,callerid_mal_formado) AS control FROM company WHERE account_number='${user_name}') INLINE</i></div><div><i>EXECUTE sofia/external/965462224@78.136.81.1 odbc_query(SELECT CONCAT(caronte,callerid_mal_formado) AS control FROM company WHERE account_number='117201')</i></div></div><div><i>Dialplan: sofia/external/965462224@78.136.81.1 ANTI-Action set(control_origen=${control})</i></div><div><i>2015-09-02 16:21:08.046388 [DEBUG] mod_dptools.c:1498 SET sofia/external/965462224@78.136.81.1 [control_origen]=[UNDEF]</i></div><div><i><br></i></div><div><i>Any ideas?</i></div>                                            </div></body>
</html>