04-23-2023 05:36 AM
Help
Ok My CMS has seven digit cospaces on it. The CMS is Neighbored to my Expressway.
When some for example dials 6511806 there is a search replace rule to send 65118(\d{2}) replace with \1@domain.com to the CMS and works fine.
Now my issue is someone dialing in 10 digit so I made a rule example: 31165118(\d{2}) and replace 651(\d{2})@domain.com to the CMS. Does not work.
The search history show that the rule changes the URI to 65118d{2}@domain.com ?
I have tried different variations but still not working .. Any help is appreciated.
Need the rule to remove the 311 forward 65118xx to the CMS.
Thank you ahead of time.
Solved! Go to Solution.
05-01-2023 10:26 PM
In your example above, you match 31165118(\d{2}), and to carry those two digits over, your replace string would need to be 65118\1@domain\.com
If you ever need to test out regex strings, I'd suggest using the regex101 web site: regex101: build, test, and debug regex
Please remember to mark helpful responses and to set your question as answered if appropriate.
05-24-2023 06:19 PM
You should be able to do it in a similar fashion using a Search rule with a regex match instead of the transform and prefix match combo.
Mode: Alias Pattern Match
Pattern Type: Regex
Pattern String: (698437\d(2})@IP
Pattern Behaviour: Replace
Replace String: \1
Target: Site A
Please remember to mark helpful responses and to set your question as answered if appropriate.
05-01-2023 10:26 PM
In your example above, you match 31165118(\d{2}), and to carry those two digits over, your replace string would need to be 65118\1@domain\.com
If you ever need to test out regex strings, I'd suggest using the regex101 web site: regex101: build, test, and debug regex
Please remember to mark helpful responses and to set your question as answered if appropriate.
05-02-2023 12:35 AM
Thank. I have another question about the transforms and search rules.
My issue is outbound dialing from my CMS >Expressway Core > Neighbor zone.
Example: I have Neighbor Zone with Site A (h.323 and SIP TLS port 5061) , Neighbor Zone with CMS (SIP TLS Port 5061).
I want to dial out to a system at site A from the CMS using Cisco Meeting Manager.
When I dial the 10 digit number it gets to the Expressway as alias@domain and then changes to alias@IP Address of the Expressway.
Now what need is to strip the address and only forward the digits to the site A.
I have a transform: Replace (698437)(\d(2})@IP Address to \1\2
I have a pre search Prefix rule 698437 target site A.
I don't like using transforms and was trying to create a search rule but to get it working I had to create the transform.
Any ideas ?
05-24-2023 06:19 PM
You should be able to do it in a similar fashion using a Search rule with a regex match instead of the transform and prefix match combo.
Mode: Alias Pattern Match
Pattern Type: Regex
Pattern String: (698437\d(2})@IP
Pattern Behaviour: Replace
Replace String: \1
Target: Site A
Please remember to mark helpful responses and to set your question as answered if appropriate.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide