<HTML><BODY>Thanks, that is work. Can U explain? Can U do the same but with the help of several conditions with AND logic (!a & !b & d) and with <SPAN class=hps>separate <FONT style="BACKGROUND-COLOR: #ffff99" face="Courier New">^(\d{3,16})? - condition?</FONT></SPAN><BR><BR><BR>Среда, 27 февраля 2013, 5:33 -05:00 от Scott <8f27e956@gmail.com>:<BR>
<BLOCKQUOTE style="BORDER-LEFT: #0857a6 1px solid; PADDING-BOTTOM: 0px; MARGIN: 10px; PADDING-LEFT: 10px; PADDING-RIGHT: 0px; PADDING-TOP: 0px" class=mailru-blockquote>
<DIV>
<DIV class="js-helper js-readmsg-msg">
<STYLE type=text/css></STYLE>
<DIV id=style_13619617110000000458 class=mr_read__body><BASE href="https://e.mail.ru/cgi-bin/" target=_self>
<DIV id=style_13619617110000000458_BODY><SPAN style="BACKGROUND-COLOR: rgb(255,255,153)"><SPAN style="FONT-FAMILY: courier new,monospace"><!-- eavesdrop --><BR><extension name="record_3..16_digits" continue="true"><BR><condition field="${is_already_recording}</SPAN>" expression="^$"/><BR></SPAN>
<DIV><SPAN style="FONT-FAMILY: courier new,monospace"><SPAN style="BACKGROUND-COLOR: rgb(255,255,153)"><condition field="destination_number" expression="(?!^399|400$)^\d{3,16}?$" > <SPAN style="BACKGROUND-COLOR: rgb(255,0,0)"><!-- regex#2 --></SPAN><BR> <action ... /><BR></condition><BR></SPAN><BR></SPAN><SPAN style="FONT-FAMILY: courier new,monospace"></SPAN></DIV>"regex#2", as written, returns TRUE providing that dest_num matches a '\d{3,16} pattern but is NOT 399 or 400. Therefore,<BR><BR>399 = false<BR>400 = false<BR>4001 = true<BR>4005551212 = true<BR>416 = true<BR>4165551212 = true<BR>1234 = true<BR>ANONYMOUS = false<BR><BR>There is very, very little that CANNOT be done with native regex.<BR><BR>If you need me to "explain" the regex construction, let me know.<BR><BR>Cheers,<BR>/Scott<BR><SPAN style="BACKGROUND-COLOR: rgb(153,153,153)"><SPAN></SPAN></SPAN><BR><BR><BR><BR><BR>
<DIV>On 26 February 2013 03:01, Dmitriy Shumaev <SPAN dir=ltr><<A href="https://e.mail.ru/cgi-bin/sentmsg?mailto=mailto%3apm_zefman_r@mail.ru" target=_blank>pm_zefman_r@mail.ru</A>></SPAN> wrote:<BR>
<BLOCKQUOTE style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex">
<DIV>Hi<BR><BR>I want to record all sessions, except calls to group numbers and to IVR. So I need something like:<BR> <!-- eavesdrop --><BR> <extension name="record_3..16_digits" continue="true"><BR> <condition field="${is_already_recording}" expression="^$"/><BR> <condition field="destination_number" expression!="^(400)$"/> <!--NOT EQUAL--><!-- IVR --><BR> <condition field="destination_number" expression!="^(399)$"/> <!--NOT EQUAL--><!-- Group number --><BR> <condition field="destination_number" expression="^(\d{3,16})$"><BR> <action application="set" data="RECORD_TITLE=Recording ${caller_id_name} ${caller_id_number} to ${destination_number} at ${strftime(%Y-%m-%d %H:%M)}"/><BR> <action application="set" data="RECORD_STEREO=true"/><BR> <action application="export" data="ignore_early_media=true"/><BR> <action application="set" data="media_bug_answer_req=true"/><BR> <action application="record_session" data="$${base_dir}/recordings/archive/${strftime(%Y-%m-%d-%H-%M-%S)}_${caller_id_name}_${caller_id_number}_2_${destination_number}.mp3"/><BR> <action application="export" data="is_already_recording=true"/><BR> </condition><BR> </extension><BR>. <SPAN>But the syntax</SPAN> <SPAN>of condition </SPAN><SPAN>does not allow the</SPAN> <SPAN>operator "</SPAN><SPAN>not equal" or "!=". What should I do?<BR><BR><BR>With best regards, Shumaev DA, KBR Ltd.</SPAN></DIV><BR>_________________________________________________________________________<BR>Professional FreeSWITCH Consulting Services:<BR><A href="https://e.mail.ru/cgi-bin/sentmsg?mailto=mailto%3aconsulting@freeswitch.org" target=_blank>consulting@freeswitch.org</A><BR><A href="http://www.freeswitchsolutions.com" target=_blank>http://www.freeswitchsolutions.com</A><BR><BR>FreeSWITCH-powered IP PBX: The CudaTel Communication Server<BR><A href="http://www.cudatel.com" target=_blank>http://www.cudatel.com</A><BR><BR>Official FreeSWITCH Sites<BR><A href="http://www.freeswitch.org" target=_blank>http://www.freeswitch.org</A><BR><A href="http://wiki.freeswitch.org" target=_blank>http://wiki.freeswitch.org</A><BR><A href="http://www.cluecon.com" target=_blank>http://www.cluecon.com</A><BR><BR>FreeSWITCH-users mailing list<BR><A href="https://e.mail.ru/cgi-bin/sentmsg?mailto=mailto%3aFreeSWITCH%2dusers@lists.freeswitch.org" target=_blank>FreeSWITCH-users@lists.freeswitch.org</A><BR><A href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target=_blank>http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</A><BR>UNSUBSCRIBE:<A href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target=_blank>http://lists.freeswitch.org/mailman/options/freeswitch-users</A><BR><A href="http://www.freeswitch.org" target=_blank>http://www.freeswitch.org</A><BR><BR></BLOCKQUOTE></DIV><BR></DIV>
<DIV>_________________________________________________________________________<BR>Professional FreeSWITCH Consulting Services:<BR><A href="https://e.mail.ru/cgi-bin/sentmsg?compose&To=consulting@freeswitch.org">consulting@freeswitch.org</A><BR><A href="http://www.freeswitchsolutions.com" target=_blank>http://www.freeswitchsolutions.com</A><BR><BR>FreeSWITCH-powered IP PBX: The CudaTel Communication Server<BR><A href="http://www.cudatel.com" target=_blank>http://www.cudatel.com</A><BR><BR>Official FreeSWITCH Sites<BR><A href="http://www.freeswitch.org" target=_blank>http://www.freeswitch.org</A><BR><A href="http://wiki.freeswitch.org" target=_blank>http://wiki.freeswitch.org</A><BR><A href="http://www.cluecon.com" target=_blank>http://www.cluecon.com</A><BR><BR>FreeSWITCH-users mailing list<BR><A href="https://e.mail.ru/cgi-bin/sentmsg?compose&To=FreeSWITCH%2dusers@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</A><BR><A href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target=_blank>http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</A><BR>UNSUBSCRIBE:<A href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target=_blank>http://lists.freeswitch.org/mailman/options/freeswitch-users</A><BR><A href="http://www.freeswitch.org" target=_blank>http://www.freeswitch.org</A><BR><BR></DIV><BASE href="https://e.mail.ru/cgi-bin/" target=_self></DIV></DIV></DIV></BLOCKQUOTE><BR></BODY></HTML>