How about...<br><br><div><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; "><p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">
<span style="font-size: 9pt; font-family: 'Courier New'; ">exten => _X.,1,NoOp()</span></p><p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span style="font-size: 9pt; font-family: 'Courier New'; ">exten => _X.,2,Set(DEVICE=${CUT(CHANNEL,,1)})</span></p>
<p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span style="font-size: 9pt; font-family: 'Courier New'; ">exten => _X.,3,Set(NULL="${REALTIME(agents,device,${DEVICE})}")</span></p>
<p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span style="font-size: 9pt; font-family: 'Courier New'; ">exten => _X.,4,Set(usernamepair=${CUT(NULL,\,,1)})</span></p>
<p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span style="font-size: 9pt; font-family: 'Courier New'; ">exten => _X.,5,Set(username=${CUT(usernamepair,=,2)})</span></p>
<p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span style="font-size: 9pt; font-family: 'Courier New'; ">exten => _X.,6,NoOp(DEVICE is ${DEVICE})</span></p>
<p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span style="font-size: 9pt; font-family: 'Courier New'; ">exten => _X.,7,NoOp(USERNAME is ${USERNAME})</span></p>
<p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span style="font-size: 9pt; font-family: 'Courier New'; ">exten => _X.,8,NoOp(username is ${username})</span></p>
<p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span style="font-size: 9pt; font-family: 'Courier New'; "><br></span></p><p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">
<font class="Apple-style-span" face="'Courier New'" size="3"><span class="Apple-style-span" style="font-size: 12px;">the REALTIME function returns a delimited string, it doesn't automatically assign variables...</span></font></p>
<p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><font class="Apple-style-span" face="'Courier New'" size="3"><span class="Apple-style-span" style="font-size: 12px;"><br>
</span></font></p><p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><font class="Apple-style-span" face="'Courier New'" size="3"><span class="Apple-style-span" style="font-size: 12px;">Perhaps you are thinking of the realtime application which would assign variables? That has however was deprecated in 1.4 and has been removed from 1.6 in favour of the function which only returns a string...</span></font></p>
<p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><font class="Apple-style-span" face="'Courier New'" size="3"><span class="Apple-style-span" style="font-size: 12px;"><br>
</span></font></p><p class="MsoNormal" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><font class="Apple-style-span" face="'Courier New'" size="3"><span class="Apple-style-span" style="font-size: 12px;">d</span></font></p>
</span></div><div><br><div class="gmail_quote">On 29 March 2010 21:42, Jason Walker <span dir="ltr"><<a href="mailto:jason.walker@amgsrv.com">jason.walker@amgsrv.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div lang="EN-US" link="blue" vlink="purple">
<div>
<p class="MsoNormal">It seems that my realtime is not assigning channel variables
correctly.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">INFO</p>
<p class="MsoNormal">Asterisk 1.6.0.26</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">Exten.conf</p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New"">exten => _X.,1,NoOp()</span></p>
<p class="MsoNormal"><span style="font-size:9.0pt;font-family:"Courier New"">exten
=> _X.,2,Set(DEVICE=${CUT(CHANNEL,,1)})</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New"">exten => _X.,3,Set(NULL="${REALTIME(agents,device,${DEVICE})}")</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New"">exten => _X.,4,NoOp(DEVICE is ${DEVICE})</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New"">exten => _X.,5,NoOp(USERNAME is ${USERNAME})</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New"">exten => _X.,6,NoOp(username is ${username})</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> </span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> </span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New"">CLI </span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> </span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> -- Executing [x@default:1] NoOp("SIP/1156-000055ce",
"") in new stack</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> -- Executing [x@default:2]
Set("SIP/1156-000055ce", "DEVICE=SIP/1156") in new stack</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> -- Executing [x@default:3]
Set("SIP/1156-000055ce", "NULL="username=john.smith,name=John
Smith,department=Dept_A,routable=no,extension=1234,device=SIP/1156,voicemail=no,monitor=yes,visible=yes,date_modified=2010-02-09
14:12:01,"") in new stack</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> -- Executing [x@default:4]
NoOp("SIP/1156-000055ce", "DEVICE is SIP/1156") in new
stack</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> -- Executing [x@default:5]
NoOp("SIP/1156-000055ce", "USERNAME is ") in new stack</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> -- Executing [x@default:6]
NoOp("SIP/1156-000055ce", "username is ") in new stack</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> </span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New"">So I can see it is getting info from the database in
Line 3</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> </span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New"">But only the direct set variable command (Line 2) and
Result (Line 4) work</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> </span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New"">Lines 5 and 6 do not get the john.smith assigned</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> </span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New"">Help</span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> </span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="font-size:9.0pt;font-family:"Courier New""> </span></p>
</div>
<pre>Confidentiality Statement & Notice: This email is covered by the
Electronic Communications Privacy Act, 18 U.S.C. 2510-2521 and
intended only for the use of the individual or entity to whom it is
addressed. Any review, retransmission, dissemination to unauthorized
persons or other use of the original message and any attachments is
strictly prohibited. If you received this electronic transmission in error,
please reply to the above-referenced sender about the error and
permanently delete this message. Thank you for your cooperation.
</pre></div>
<br>--<br>
_____________________________________________________________________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" target="_blank">http://www.api-digital.com</a> --<br>
New to Asterisk? Join us for a live introductory webinar every Thurs:<br>
<a href="http://www.asterisk.org/hello" target="_blank">http://www.asterisk.org/hello</a><br>
<br>
asterisk-users mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
<a href="http://lists.digium.com/mailman/listinfo/asterisk-users" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br></blockquote></div><br></div>