09-30-2010 02:43 PM - edited 03-16-2019 01:07 AM
Is it possible to run a SQL querry for a perticular Calling number or Called number from Callmanager 7 CLI ?
Solved! Go to Solution.
10-01-2010 12:56 AM
Hi
You can use the 'like' keyword to enable wildcard matching, and the wildcard character is %
So for example:
All numbers starting with 55212448
run sql select callingpartynumber, originalcalledpartynumber, finalcalledpartynumber,datetimestamporigination from car:tbl_billing_data where originalcalledpartynumber like '55212448%'
All numbers containing 55212448
run sql select callingpartynumber, originalcalledpartynumber, finalcalledpartynumber,datetimestamporigination from car:tbl_billing_data where originalcalledpartynumber like '%55212448%'
Regards
Aaron
Please rate helpful posts...
10-01-2010 01:03 AM
Yup,
Aaron mentioned should work.
Basically if you should focus on the query syntax and see what columns are there to get the output from the tables using sql.
Once you get the hang of that, you can easily manupilate the queries to get desired results..
HTH
kunal
09-30-2010 02:55 PM
Hello,
try this query from the cli of the publisher:
run sql select callingpartynumber, originalcalledpartynumber, finalcalledpartynumber,
datetimestamporigination from car:tbl_billing_data where originalcalledpartynumber = '911'
basically the feild after where is the one which we are getting the output for, it can calling party, called party, and the '911' means the number(calling or called); if you play around with it, i am sure you will get the hang of it, if you have any specific question, do let me know.
HTH
kunal
09-30-2010 02:55 PM
Also i am assuming CDR data is woking with out any issues in the cluster.
Regards
Kunal
09-30-2010 06:28 PM
Kunal,
Thanks for the reply.. I will test it tomorrow and let you know.
Rav
09-30-2010 08:31 PM
Kunal,
It worked just fine for perticular Called number. If I want to list all the calls originated from a perticular site, by its Calling number how should I formulate the querry. Can we list all the calls originated by a DID range begins with +55212448 ?
Thanks in advance,
Rav
10-01-2010 12:56 AM
Hi
You can use the 'like' keyword to enable wildcard matching, and the wildcard character is %
So for example:
All numbers starting with 55212448
run sql select callingpartynumber, originalcalledpartynumber, finalcalledpartynumber,datetimestamporigination from car:tbl_billing_data where originalcalledpartynumber like '55212448%'
All numbers containing 55212448
run sql select callingpartynumber, originalcalledpartynumber, finalcalledpartynumber,datetimestamporigination from car:tbl_billing_data where originalcalledpartynumber like '%55212448%'
Regards
Aaron
Please rate helpful posts...
10-01-2010 01:03 AM
Yup,
Aaron mentioned should work.
Basically if you should focus on the query syntax and see what columns are there to get the output from the tables using sql.
Once you get the hang of that, you can easily manupilate the queries to get desired results..
HTH
kunal
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