×

Warning message

  • Cisco Support Forums is in Read Only mode while the site is being migrated.
  • Cisco Support Forums is in Read Only mode while the site is being migrated.

find dialed number mapping to call type

Answered Question
Mar 22nd, 2014
User Badges:

hello

iam tasked with finding what call types are mapped to what dialed numbers. our envionrnment have hundereds of numbers and i want a way to make this a much faster process. is there a sql query that can be run?

- aashish

Correct Answer by Omar Deen about 3 years 5 months ago

aashish

You can use the query below that will return the dialed number string, each peripheral created for said DN string, what call type is mapped to the DN, and what routing script the call type is scheduled to. 

SELECT DN.EnterpriseName AS Peripheral, CT.EnterpriseName AS CallType, MS.EnterpriseName AS ScriptName, DN.DialedNumberString AS DialedNumber
FROM Call_Type CT, Dialed_Number DN, Dialed_Number_Map DNM, Call_Type_Map CTM, Master_Script MS
WHERE MS.MasterScriptID IS NOT NULL
AND DNM.CallTypeID = CT.CallTypeID
AND DN.DialedNumberID = DNM.DialedNumberID
AND CT.CallTypeID = CTM.CallTypeID
AND CTM.MasterScriptID = MS.MasterScriptID
GROUP BY CT.EnterpriseName, DN.EnterpriseName, MS.EnterpriseName, DN.DialedNumberString
ORDER BY DN.EnterpriseName

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 5 (2 ratings)
Loading.
Correct Answer
Omar Deen Sun, 03/23/2014 - 00:07
User Badges:
  • Silver, 250 points or more

aashish

You can use the query below that will return the dialed number string, each peripheral created for said DN string, what call type is mapped to the DN, and what routing script the call type is scheduled to. 

SELECT DN.EnterpriseName AS Peripheral, CT.EnterpriseName AS CallType, MS.EnterpriseName AS ScriptName, DN.DialedNumberString AS DialedNumber
FROM Call_Type CT, Dialed_Number DN, Dialed_Number_Map DNM, Call_Type_Map CTM, Master_Script MS
WHERE MS.MasterScriptID IS NOT NULL
AND DNM.CallTypeID = CT.CallTypeID
AND DN.DialedNumberID = DNM.DialedNumberID
AND CT.CallTypeID = CTM.CallTypeID
AND CTM.MasterScriptID = MS.MasterScriptID
GROUP BY CT.EnterpriseName, DN.EnterpriseName, MS.EnterpriseName, DN.DialedNumberString
ORDER BY DN.EnterpriseName

Actions

This Discussion