03-14-2005 01:39 PM - edited 03-18-2019 04:20 PM
I have several extension ranges of call handers Id like to delete... What is the best way of doing this? There seem to have been a lot of call handlers we created for extensions that don't exist and Im just trying to clean things up a bit. Bulk Edit has been a great tool in making large changes, but I don't see anything to delete call handlers in bulk... Is there a way?
Thank you
03-14-2005 02:00 PM
There's a bulk subscriber delete tool, but I never put together a bulk handler delete - this is the first request I've had for something like that.
This can be done through an SQL query if need be, but it's a little complex sine you want to make real sure you don't delete any primary call handlers (those handlers associtated with subscribers) or remove handlers actually in use.
Most handlers are not actually assigned extensions (They're optional for handlers) - it's a little unusual for extensions to be in use unless they're used as a routing device (i.e. handlers in an audio text application would typically not have extensions assigned to them) - this makes a bulk delete tool a little awkward for most installations.
03-14-2005 02:46 PM
Hey Jeff
Yes, these are routing handlers... Not many folks have DID's... so those without voicemail need a call handler to route calls to their extensions... Somehow we did a bulk create or import and ended up doing ranges of extensions I guess to create them... Im doing cleanup and discovered we have a lot of handlers where extensions aren't even present in the call manager.. Id like some way of getting rid of them without going into each one.. and im not a sql guy, so Id be afraid to dabble in SQL to that extent... I assume if im the only one that has ever requsted, there isn't much drive for you to create something for me :)
03-14-2005 03:06 PM
It's not that tough to do in SQL directly - you can use the Query Analyzer tool from MS or the Data Link Explorer (which you'll find in the Tools Depot on your desktop) to enter the following query:
SELECT CallHandler.Alias, DTMFAccessID.DTMFAccessID
FROM CallHandler INNER JOIN DTMFAccessID
ON CallHandler.CallHandlerObjectID=DTMFAccessID.ParentObjectID
WHERE DTMFAccessID.DTMFAccessID BETWEEN 5000 and 5500
This will just show you the list of application call handlers that have primary extensions between 5000 and 5500 (obviusly you stick your own extension range in there). This wont pick up primary call handlers (associated with subscribers) becasue the subscriber's OBjectID is listed as the parent.
When you're happy that you have the list of handlers you want, then just modify the query to be a delete instead of a select like this:
DELETE CallHandler
FROM CallHandler INNER JOIN DTMFAccessID
ON CallHandler.CallHandlerObjectID=DTMFAccessID.ParentObjectID
WHERE DTMFAccessID.DTMFAccessID BETWEEN 5000 and 5500
Of course, snag yourself a fresh backup with DiRT before embarking on this type of thing... always a good idea.
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