cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
357
Views
0
Helpful
5
Replies

SQL Query

Lalo Nunez
Beginner
Beginner

Morning, I need some assistance with an SQL Query. We are trying to determine what FXS ports have not been used and can possibly be re-purposed for other analog devices.

I see in RTMT the counters for Calls Completed, but I am trying to get this information through a SQL Query. Thanks.

1 Accepted Solution

Accepted Solutions

Here is a query that will list all calls to/from an analog MGCP port on a gateway whose name matches "HQ".

run sql car select datetimestamporigination, callingpartynumber, origdevicename, originalcalledpartynumber, destdevicename, duration from tbl_billing_data where origdevicename like 'AALN%HQ%' or destdevicename like 'AALN%HQ%'

View solution in original post

5 Replies 5

Lalo Nunez
Beginner
Beginner

Forgot to mention running UCM 10.5.2.10000-5.

Jaime Valencia
Hall of Fame Cisco Employee Hall of Fame Cisco Employee
Hall of Fame Cisco Employee

I don't believe there's any query that will give you that, CUCM doesn't keep track of whether you use a phone, or something else, in a table (I believe only EM does that). That might be something to weed out from CAR/CDR reports, see how many ports you have, and for which ones you DO see calls, for the ones you don't see calls, are likely the ones that are not being used.

HTH

java

if this helps, please rate

Thanks Jaime for the quick response.

Here is a query that will list all calls to/from an analog MGCP port on a gateway whose name matches "HQ".

run sql car select datetimestamporigination, callingpartynumber, origdevicename, originalcalledpartynumber, destdevicename, duration from tbl_billing_data where origdevicename like 'AALN%HQ%' or destdevicename like 'AALN%HQ%'

Thanks Anthony. That definitely helps determine if any calls have gone through a specific port or group of ports.

I can continue to use RTMT, but for any ports that report "0" Call Completed I can use the query above. Since resetting a FXS port causes the counter to for Calls Completed go to zero, this will help verify if that indeed is the case.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Recognize Your Peers