04-12-2023 05:08 AM
Dear community,
This translation only picks three digits and maps it to 56xxx. However, I would like it to pick 5[6-9]xxx. what needs to be changed?
!
voice translation-rule 1
rule 1 /\(...\)/ /56\1/
!
voice translation-rule 2
rule 1 /.+\(...\)$/ /\1/
rule 2 /56/ //
!
voice translation-rule 3
rule 1 /56\(...\)/ /0956106\1/
!
voice translation-profile PROVIDER1
translate called 1
!
voice translation-profile PROVIDER2
translate calling 3
!
voice translation-profile HQ-OUTGOING
translate calling 2
!
voice translation-profile PROVIDER3
translate called 1
!
Regards,
Isaac.
Solved! Go to Solution.
04-12-2023 08:46 AM
You cannot have to rules with the same match-statement.
Doesn't matter if you want to match 3 digits, or 10 digits or whatever.
If it would work, same question to you applies: How should the router know, which rule to use?
E.g.
rule 1 /.../ /57\0/ --> matches 3 digits and adds the prefix 57
rule 2 /.../ /56\0/ --> matches 3 digits and adds the prefix 56
So the question to you now: how should the router know to use rule 1 and not rule 2? Or vice-versa?
Correct answer: He doesn't know, therefore you cannot have multiple rules with the same matching statement
To your example with 10 digits:
If you want to receive calls to 57xxx or 56xxx, ... you have to differentiat your 10 digit dial-plan, as already explained in my previous post and also by @Nithin Eluvathingal
04-13-2023 02:18 AM - edited 04-13-2023 04:02 AM
Let me try to explain this as easy and clearly as I possibly can.
As has been pointed out in multiple answers by me and @b.winter and @Nithin Eluvathingal you cannot have multiple ranges of extensions in CM that uses the same number on the gateway. I don't know how to make this any clearer to you? There is really no point in doing what you're trying as you have been assigned a 1000 numbers from your Telco, aka 000 to 999, with this you cannot use 3000 extension (numbers) in CM and try somehow magically have those share the 1000 numbers that you'd been assigned.
Hopefully this clears out things for you. If not please reach out to a reputable Cisco partner for help with this as we apparantly cannot help you with this in the community.
04-12-2023 06:03 AM
Your rules are for matching three digits 000-999 and add 56, and if understood correctly its working as expected. What you expect by "I would like it to pick 5[6-9]xxx"
04-12-2023 06:12 AM
Nithin,
Thanks for your response.
I would like it to translate from matched to 57xxx or 58xxx or 59xxx . It doesnt allow that kind of translation but gives the error as a duplicate entry.
Regards,
Isaac.
04-12-2023 06:30 AM
Something like "rule 1 /.../ /5[6-9]\1/" won't work. Because how should the router know, if you he should add 56, or 57, ... to the matched number? Just by guessing?
You need to define your matching statement, to define, then which prefix should be added.
E.g.
rule 1 /[1-2]../ /56\1/
rule 2 /[3-4]../ /57\1/
...
04-12-2023 07:01 AM - edited 04-12-2023 07:03 AM
b.winter,
thanks for your reply. I believe you we are on the right track with your recommendation.
However, I have one dilemma with the matching statement. If I expect to receive both 56444 and 57444 how will the match statement look like, i get lost here.
rule 1 /[1-9]../ /56\1/
rule 2 /[1-9]../ /57\1/
configured as above but got error below
Error: Duplicate with rule 1
To make it more clear, I want to receive calls to extensions on 56xxx and 57xxx individually but something is wrong with the translation.
Regards,
Isaac.
04-12-2023 07:45 AM
That rule is wrong and it’s duplicate.
In your case you must match with 5 digit and not the last three digit.
assume you receive call with called numbers 12xxx , 13xxx , 14xxx
and if you want to translate the above to 56xxx 57xxx 58xxx
the below rule will work
rule 1 /14\(…\)/ /56\1/
rule 2 /15\(…\)/ /57\1/
rule 3 /16\(…\)/ /58\1/
04-12-2023 08:20 AM
b.winter,
Thanks for your reply.
It's still unclear to me. The scenario is that I receive random 10 digita pstn calls so I can't dictate how to match them. I just want to receive calls to any internal 56xxx,57xxx or 58xxx extension.
For some reason if I remove
rule 1 /\(...\)/ /56\1/ and replace with rule 1 /\(...\)/ /57\1/
I receive calls to 57xxx and not 56xxx as was.
Regards,
Isaac
04-12-2023 08:46 AM
You cannot have to rules with the same match-statement.
Doesn't matter if you want to match 3 digits, or 10 digits or whatever.
If it would work, same question to you applies: How should the router know, which rule to use?
E.g.
rule 1 /.../ /57\0/ --> matches 3 digits and adds the prefix 57
rule 2 /.../ /56\0/ --> matches 3 digits and adds the prefix 56
So the question to you now: how should the router know to use rule 1 and not rule 2? Or vice-versa?
Correct answer: He doesn't know, therefore you cannot have multiple rules with the same matching statement
To your example with 10 digits:
If you want to receive calls to 57xxx or 56xxx, ... you have to differentiat your 10 digit dial-plan, as already explained in my previous post and also by @Nithin Eluvathingal
04-12-2023 10:37 AM
You will not receive random 10 digit numbers from your service provider, you will receive the range of numbers that is assigned to you by the service provider. Can you please provide the number range that you have been assigned and explain what you want to translate to what? With that we should be able to help you.
04-13-2023 01:07 AM
Hi Roger,
Thanks for your reply.
What I meant is that anybody with an 10 digit number from outside the organization can call in. The expectation is that when an internal extension receives the 10 digit number, they will be able to call back since they need to know who called in the first place.
So the number issued to us by ISP is 0711099000. When calling out its translated to say 0711099558. So when calling in/inbound calls how can I translate called to internal extension 56xxx,57xxx and 58xxx?
Regards,
Isaac.
04-13-2023 01:25 AM - edited 04-13-2023 01:26 AM
So your did block is 0711099xxx.
I assume you have 1000 block numbers from 0711099000 - 0711099999
so now out of this 1000 number block which number you need to translate to 56xxx, 57xxx,58xxx
04-13-2023 01:29 AM
Nithin,
Thanks for your reply.
Yes 0711099xxx is my digit block. I want to translate any of the three 56xxx,57xxx and 58xxx. Is it possible?
Regards,
Isaac.
04-13-2023 01:51 AM
Again and again:
Which numbers of your DID block do you want to translate to 56xxx, 57xxx or 58xxx?
You cannot have a rule like this: "rule 1 /0711099\(...\)/ /5[6-8]\1/", because the router doesn't know which prefix to pick.
You cannot have wildcards options in the replace statement (the red statement).
Your problem is not a technical one. In my opinion, you don't understand what we are trying to tell you and I think, you don't really know how translation patterns work.
04-13-2023 02:08 AM
b.winter,
Thanks for your reply.
I do acknowledge a knowledge gap, I have read the recommended guides but not getting it. As you understand my scenario what would you do/advise to work around my predicament?
I simply want to make calls and present my assigned number(0711099xxx) to outsiders and be able to see calls from outsiders to my company.
Regards,
Isaac.
04-13-2023 02:18 AM
Again and again and again and ...:
Which numbers of your DID range should be translated to 56xxx, 57xxx or 58xxx?
If you don't answer this simple question, nobody will be able to help you. This is not a technical question.
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