<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Consolas;
panose-1:2 11 6 9 2 2 4 3 2 4;}
@font-face
{font-family:"Helvetica 75 Bold";
panose-1:2 11 8 4 2 2 2 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
font-size:11.0pt;
font-family:"Calibri",sans-serif;
mso-ligatures:standardcontextual;
mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
pre
{mso-style-priority:99;
mso-style-link:"Préformaté HTML Car";
margin:0cm;
font-size:10.0pt;
font-family:"Courier New";}
span.PrformatHTMLCar
{mso-style-name:"Préformaté HTML Car";
mso-style-priority:99;
mso-style-link:"Préformaté HTML";
font-family:Consolas;}
span.EmailStyle23
{mso-style-type:personal-reply;
font-family:"Arial",sans-serif;
color:windowtext;
font-weight:normal;
font-style:normal;
text-decoration:none none;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;
mso-ligatures:none;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="FR" link="blue" vlink="purple" style="word-wrap:break-word">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif">Hi Bogdan,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif">Thank you for your answer.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif">And is it possible to use that
</span><span lang="EN-US" style="font-family:"Courier New"">lookup("location") function to
</span><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif">put the “registered socket” field in a variable in order to use it for my script ?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif">Regards,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"> Guillaume<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="mso-ligatures:none;mso-fareast-language:FR">De :</span></b><span style="mso-ligatures:none;mso-fareast-language:FR"> Bogdan-Andrei Iancu <bogdan@opensips.org>
<br>
<b>Envoyé :</b> jeudi 28 mars 2024 11:15<br>
<b>À :</b> OpenSIPS users mailling list <users@lists.opensips.org>; DESGEORGE Guillaume INNOV/IT-S <guillaume.desgeorge@orange.com><br>
<b>Objet :</b> Re: [OpenSIPS-Users] How to access to a column of a location database<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<div align="center">
<table class="MsoNormalTable" border="1" cellspacing="3" cellpadding="0" style="background:lightyellow;border:solid black 1.0pt">
<tbody>
<tr>
<td style="border:none;padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal"><strong><span style="font-size:8.5pt;font-family:"Calibri",sans-serif;color:black">CAUTION</span></strong><span style="font-size:8.5pt;color:black"> : This email originated outside the company. Do not click on any links or open attachments
unless you are expecting them from the sender. </span><span style="font-size:8.5pt;mso-ligatures:none;mso-fareast-language:FR"><o:p></o:p></span></p>
</td>
</tr>
<tr>
<td style="border:none;padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal"><strong><span style="font-size:8.5pt;font-family:"Calibri",sans-serif;color:black">ATTENTION</span></strong><span style="font-size:8.5pt;color:black"> : Cet e-mail provient de l'extérieur de l'entreprise. Ne cliquez pas sur les liens ou
n'ouvrez pas les pièces jointes à moins de connaitre l'expéditeur.</span><span style="font-size:8.5pt"><o:p></o:p></span></p>
</td>
</tr>
</tbody>
</table>
</div>
<p class="MsoNormal"><br>
<br>
<span style="font-family:"Courier New"">Hi Guillaume,<br>
<br>
The registered contact (and the additional info) is fetched via the lookup("location") function. It also sets the registered socket for the routing the current request.<br>
<br>
Regards,<br>
<br>
</span><o:p></o:p></p>
<pre>Bogdan-Andrei Iancu<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre>OpenSIPS Founder and Developer<o:p></o:p></pre>
<pre> <a href="https://www.opensips-solutions.com/">https://www.opensips-solutions.com</a><o:p></o:p></pre>
<pre> <a href="https://www.siphub.com/">https://www.siphub.com</a><o:p></o:p></pre>
<div>
<p class="MsoNormal">On 22.03.2024 10:57, <a href="mailto:guillaume.desgeorge@orange.com">
guillaume.desgeorge@orange.com</a> wrote:<o:p></o:p></p>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif">Hi everybody,</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif">In my routing logic of my “opensips.cfg” file, I’m trying to access the “socket” field of the location table of registered contacts.</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif">I have the registering informations correctly written in MySQL location table but can’t find a function to access it.</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif">I’d like to have a function which I give the registered username and can give me back the associated socket.</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif">Is the lookup () function the good one ? I didn’t understand how to use it that way.</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif">Thanks for your help,</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"> </span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"> Guillaume</span><o:p></o:p></p>
<div style="margin-left:5.0pt;margin-top:5.0pt;margin-right:5.0pt;margin-bottom:5.0pt">
<p class="MsoNormal" align="center" style="text-align:center"><span style="font-size:8.0pt;font-family:"Helvetica 75 Bold",sans-serif;color:#ED7D31">Orange Restricted</span><o:p></o:p></p>
</div>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"> </span><o:p></o:p></p>
<p class="MsoNormal"><span style="mso-ligatures:none;mso-fareast-language:FR"><o:p> </o:p></span></p>
<p align="center" style="margin:5.0pt;text-align:center"><span style="font-size:8.0pt;font-family:"Helvetica 75 Bold",sans-serif;color:#ED7D31">Orange Restricted<o:p></o:p></span></p>
<pre>____________________________________________________________________________________________________________<o:p></o:p></pre>
<pre>Ce message et ses pieces jointes peuvent contenir des informations confidentielles ou privilegiees et ne doivent donc<o:p></o:p></pre>
<pre>pas etre diffuses, exploites ou copies sans autorisation. Si vous avez recu ce message par erreur, veuillez le signaler<o:p></o:p></pre>
<pre>a l'expediteur et le detruire ainsi que les pieces jointes. Les messages electroniques etant susceptibles d'alteration,<o:p></o:p></pre>
<pre>Orange decline toute responsabilite si ce message a ete altere, deforme ou falsifie. Merci.<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre>This message and its attachments may contain confidential or privileged information that may be protected by law;<o:p></o:p></pre>
<pre>they should not be distributed, used or copied without authorisation.<o:p></o:p></pre>
<pre>If you have received this email in error, please notify the sender and delete this message and its attachments.<o:p></o:p></pre>
<pre>As emails may be altered, Orange is not liable for messages that have been modified, changed or falsified.<o:p></o:p></pre>
<pre>Thank you.<o:p></o:p></pre>
<p class="MsoNormal"><span style="mso-ligatures:none;mso-fareast-language:FR"><br>
<br>
<o:p></o:p></span></p>
<pre>_______________________________________________<o:p></o:p></pre>
<pre>Users mailing list<o:p></o:p></pre>
<pre><a href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a><o:p></o:p></pre>
<pre><a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><o:p></o:p></pre>
</blockquote>
<p class="MsoNormal"><span style="mso-ligatures:none;mso-fareast-language:FR"><o:p> </o:p></span></p>
</div>
<pre>_________________<wbr>______________________________<wbr>______________________________<wbr>______________________________<wbr>_
Ce message et ses pieces jointes peuvent contenir des informations confidentielles ou privilegiees et ne doivent donc
pas etre diffuses, exploites ou copies sans autorisation. Si vous avez recu ce message par erreur, veuillez le signaler
a l'expediteur et le detruire ainsi que les pieces jointes. Les messages electroniques etant susceptibles d'alteration,
Orange decline toute responsabilite si ce message a ete altere, deforme ou falsifie. Merci.
This message and its attachments may contain confidential or privileged information that may be protected by law;
they should not be distributed, used or copied without authorisation.
If you have received this email in error, please notify the sender and delete this message and its attachments.
As emails may be altered, Orange is not liable for messages that have been modified, changed or falsified.
Thank you.</pre></body>
</html>