<div dir="auto">Thank u so much for the confirmation. <div dir="auto"><br></div><div dir="auto">Although I have tested this in the same way and it's working . Still after you confirmation I am double sure that I am in the right track . </div><div dir="auto"><br></div><div dir="auto">Thank u once again . </div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, 23 Oct 2023, 19:00 Ben Newlin, <<a href="mailto:Ben.Newlin@genesys.com">Ben.Newlin@genesys.com</a>> wrote:<br></div><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" style="word-wrap:break-word">
<div class="m_-4980905634243810657WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt">Yes, based on your description of the problem that transformation should work. We use that transformation to test a comma-separated list for the existence of a value in the same way.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;color:black">Ben Newlin</span><span style="font-size:11.0pt"><u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><u></u> <u></u></span></p>
<div id="m_-4980905634243810657mail-editor-reference-message-container">
<div>
<div style="border:none;border-top:solid #b5c4df 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal" style="margin-bottom:12.0pt"><b><span style="font-size:12.0pt;color:black">From:
</span></b><span style="font-size:12.0pt;color:black">Users <<a href="mailto:users-bounces@lists.opensips.org" target="_blank" rel="noreferrer">users-bounces@lists.opensips.org</a>> on behalf of Sasmita Panda <<a href="mailto:spanda@3clogic.com" target="_blank" rel="noreferrer">spanda@3clogic.com</a>><br>
<b>Date: </b>Monday, October 23, 2023 at 2:13 AM<br>
<b>To: </b>OpenSIPS users mailling list <<a href="mailto:users@lists.opensips.org" target="_blank" rel="noreferrer">users@lists.opensips.org</a>><br>
<b>Subject: </b>Re: [OpenSIPS-Users] I need some help in attr matching while forming the Branch .<u></u><u></u></span></p>
</div>
<div>
<div>
<div>
<table border="1" cellspacing="0" cellpadding="0" style="border-collapse:collapse;border:none">
<tbody>
<tr>
<td style="border:solid #b60000 1.0pt;background:white;padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal"><b><span style="font-size:12.0pt;color:#b60000"> EXTERNAL EMAIL - Please use caution with links and attachments <u></u><u></u></span></b></p>
</td>
</tr>
</tbody>
</table>
</div>
<p class="MsoNormal"><span style="font-size:9.0pt;font-family:Helvetica;color:black"><u></u> <u></u></span></p>
<div class="MsoNormal" align="center" style="text-align:center"><span style="font-size:11.0pt">
<hr size="0" width="100%" align="center">
</span></div>
</div>
<p class="MsoNormal"><span style="font-size:11.0pt">There are some changes in the requirements now . <u></u><u></u></span></p>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"><u></u> <u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">Although I appreciate your suggestion, I will go with script transformation . But not in a different way . <b> In the register I will get set of comma separated values in Call-Info </b><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><b><span style="font-size:11.0pt">header and will save that in attr column . </span></b><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"><u></u> <u></u></span></p>
</div>
<div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">Agent1: call-info : en,galileo,level1,true<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">Agent2 : call-info : en,spanish,lenovo,true<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">Agent3: call-info : en,galileo,sales,level1,true<u></u><u></u></span></p>
</div>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"><u></u> <u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">1st Invite : <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><b><span style="font-size:11.0pt">call-info : en,galileo,true</span></b><span style="font-size:11.0pt"> (I have to match the contact in which this the substring of Registered contacts Attr . ex : Agent1 and Agent3 will the matching agents
here )<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"><u></u> <u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">2nd Invite :<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><b><span style="font-size:11.0pt">call-info : en,true</span></b><span style="font-size:11.0pt"> (All there agents are matching this critaria )<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"><u></u> <u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">3rd Invite : <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><b><span style="font-size:11.0pt">call-info : spanish,lenovo,true
</span></b><span style="font-size:11.0pt">(Agent2 will match the criteria )<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"><u></u> <u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">This is kind of substring matching . Here the challenge for me is , the number of values in the Invite header is not fixed , That can be 2 , that can be 4 that can be 7 . If every comma separated value is
present in the Attr field then that contact will get call else not . <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"><u></u> <u></u></span></p>
</div>
<div>
<p class="MsoNormal"><b><span style="font-size:11.0pt">#Test for existence of string in another<br>
if ($(var(strtosearch){s.index, $var(str)}) != NULL)<br>
xlog("found $var(sstr) in $var(strtosearch)\n");</span></b><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"><u></u> <u></u></span></p>
</div>
<div>
<p class="MsoNormal"><b><span style="font-size:11.0pt;color:#cc0000">So will this help me in this case ? </span></b><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"><u></u> <u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"><br clear="all">
<u></u><u></u></span></p>
<div>
<div>
<div>
<div>
<div>
<p class="MsoNormal"><b><i><span style="font-size:11.0pt">Thanks & Regards</span></i></b><span style="font-size:11.0pt"><u></u><u></u></span></p>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt">Sasmita Panda</span></i><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt">Senior Network Testing and Software Engineer</span></i><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt">3CLogic , ph:07827611765</span></i><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
</div>
</div>
</div>
</div>
</div>
<p class="MsoNormal"><span style="font-size:11.0pt"><u></u> <u></u></span></p>
</div>
</div>
<p class="MsoNormal"><span style="font-size:11.0pt"><u></u> <u></u></span></p>
<div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">On Wed, Oct 18, 2023 at 7:10 PM Ben Newlin <<a href="mailto:Ben.Newlin@genesys.com" target="_blank" rel="noreferrer">Ben.Newlin@genesys.com</a>> wrote:<u></u><u></u></span></p>
</div>
<blockquote style="border:none;border-left:solid #cccccc 1.0pt;padding:0in 0in 0in 6.0pt;margin-left:4.8pt;margin-right:0in">
<div>
<div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">Sasmita,<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">Your examples all contain mixed use of semicolons and commas. Without any description or context, it’s very difficult to tell what or how you expect
these to match.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">Having said that, I recommend making use of OpenSIPS transformations [1]. The parameters list transformations [2] specifically, as they operate on
semicolon separated “key=value” pairs, just like you have.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">Depending on what operation you are expecting with respect to the commas, you may be able to combine that with the string select transformation [3]
to get your desired outcome.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">[1]
<a href="https://www.opensips.org/Documentation/Script-Tran-3-2" target="_blank" rel="noreferrer">
https://www.opensips.org/Documentation/Script-Tran-3-2</a><u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">[2]
<a href="https://www.opensips.org/Documentation/Script-Tran-3-2#toc60" target="_blank" rel="noreferrer">
https://www.opensips.org/Documentation/Script-Tran-3-2#toc60</a><u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">[3]
<a href="https://www.opensips.org/Documentation/Script-Tran-3-2#toc7" target="_blank" rel="noreferrer">
https://www.opensips.org/Documentation/Script-Tran-3-2#toc7</a><u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;color:black">Ben Newlin</span><span style="font-size:11.0pt"><u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
<div id="m_-4980905634243810657m_7832164249889748124mail-editor-reference-message-container">
<div>
<div style="border:none;border-top:solid #b5c4df 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal" style="margin-bottom:12.0pt"><b><span style="font-size:12.0pt;color:black">From:
</span></b><span style="font-size:12.0pt;color:black">Users <<a href="mailto:users-bounces@lists.opensips.org" target="_blank" rel="noreferrer">users-bounces@lists.opensips.org</a>> on behalf of Sasmita Panda <<a href="mailto:spanda@3clogic.com" target="_blank" rel="noreferrer">spanda@3clogic.com</a>><br>
<b>Date: </b>Wednesday, October 18, 2023 at 6:34 AM<br>
<b>To: </b>OpenSIPS users mailling list <<a href="mailto:users@lists.opensips.org" target="_blank" rel="noreferrer">users@lists.opensips.org</a>><br>
<b>Subject: </b>Re: [OpenSIPS-Users] I need some help in attr matching while forming the Branch .</span><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
<div>
<div>
<div>
<table border="0" cellspacing="0" cellpadding="0" style="border-collapse:collapse">
<tbody>
<tr>
<td style="border:solid #b60000 1.0pt;background:white;padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal"><b><span style="font-size:12.0pt;color:#b60000"> EXTERNAL EMAIL - Please use caution with links and attachments </span></b><span style="font-size:11.0pt"><u></u><u></u></span></p>
</td>
</tr>
</tbody>
</table>
</div>
<p class="MsoNormal"><span style="font-size:9.0pt;font-family:Helvetica;color:black"> </span><span style="font-size:11.0pt"><u></u><u></u></span></p>
<div class="MsoNormal" align="center" style="text-align:center"><span style="font-size:11.0pt">
<hr size="0" width="100%" align="center">
</span></div>
</div>
<p class="MsoNormal"><span style="font-size:11.0pt">Hi All , <u></u><u></u></span></p>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">Any help on this ? <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"><br clear="all">
<u></u><u></u></span></p>
<div>
<div>
<div>
<div>
<div>
<p class="MsoNormal"><b><i><span style="font-size:11.0pt">Thanks & Regards</span></i></b><span style="font-size:11.0pt"><u></u><u></u></span></p>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt">Sasmita Panda</span></i><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt">Senior Network Testing and Software Engineer</span></i><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt">3CLogic , ph:07827611765</span></i><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
</div>
</div>
</div>
</div>
</div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
</div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
<div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">On Tue, Oct 17, 2023 at 7:54 PM Sasmita Panda <<a href="mailto:spanda@3clogic.com" target="_blank" rel="noreferrer">spanda@3clogic.com</a>> wrote:<u></u><u></u></span></p>
</div>
<blockquote style="border:none;border-left:solid #cccccc 1.0pt;padding:0in 0in 0in 6.0pt;margin-left:4.8pt;margin-top:5.0pt;margin-right:0in;margin-bottom:5.0pt">
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">Hi All , <u></u><u></u></span></p>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">My requirements seem complicated to me. I dont know whether I am right or wrong . <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">I am using opensips 1.11 (I have opensips 3.2 as well )<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><b><span style="font-size:11.0pt">scenario 1: </span></b><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">989898 - is registered from 3 different contact with different call-info header . and I saved the call-info header in attr column while saving data
. <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">1 contact : call-info : x=hr,network;y=sales,z=marketing <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">2nd contact : call-info : x=hr;y=sales,z=marketing <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">3rd contact : call-info : x=hr,network;y=sales,z=marketing<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">INVITE : <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> call-info : x=hr;y=sales<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">Now while forming a branch for this INVITE , how do I compare this call-info with attr to get all the contact and then do serial forking on this ?<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><b><span style="font-size:11.0pt">scenario 2: </span></b><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
<div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">989898 - is registered from 3 different contact with different call-info header . and I saved the call-info header in attr column while saving data
. <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">1 contact : call-info : x=hr,network;y=sales,z=marketing <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">2nd contact : call-info : x=hr;y=sales,z=marketing <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">3rd contact : call-info : x=hr,network;y=sales,z=marketing<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">INVITE : <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> call-info : call-info : x=hr,network;y=sales,z=marketing<u></u><u></u></span></p>
</div>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">In this I am getting only 1 contact where there is exact match . And I am able to gove call to that contact . <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">I am stuck on the 1st scenario . I am thinking of exec module to use on this . But not getting any better examples of how I do this . Please anybody
help me out . <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">Any kind of help is appreciated . thank you in advance . <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"> <u></u><u></u></span></p>
</div>
<div>
<div>
<div>
<div>
<div>
<div>
<p class="MsoNormal"><b><i><span style="font-size:11.0pt">Thanks & Regards</span></i></b><span style="font-size:11.0pt"><u></u><u></u></span></p>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt">Sasmita Panda</span></i><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt">Senior Network Testing and Software Engineer</span></i><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt">3CLogic , ph:07827611765</span></i><span style="font-size:11.0pt"><u></u><u></u></span></p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</blockquote>
</div>
</div>
</div>
</div>
</div>
<p class="MsoNormal"><span style="font-size:11.0pt">_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.opensips.org" target="_blank" rel="noreferrer">Users@lists.opensips.org</a><br>
<a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank" rel="noreferrer">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><u></u><u></u></span></p>
</div>
</blockquote>
</div>
</div>
</div>
</div>
</div>
_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.opensips.org" target="_blank" rel="noreferrer">Users@lists.opensips.org</a><br>
<a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" rel="noreferrer noreferrer" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
</blockquote></div>