cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
544
Views
0
Helpful
1
Replies

Change Hlog setting based on CFA on DN

Mikael Hansson
Level 5
Level 5

I need to do a change of the Hlog (devicehlogdynamic) on all devices with a specific DN based on the CFA-status of that DN through AXL.

For example where DN=62990 and cfadestination is not empty or cfavoicemailenabled is true.

I know i have to do this in several steps:

1. get information if the DN is forwarded and which devices that DN belongs to.

2. update the Hlog on those devices

3. reset devices (doDeviceReset; isHardReset=false)

(if more than one device then do step 2 and 3 for each device)

Have anyone done this previously and have some code that you can share ?

Any help is appreciated. Even small contribution or examples on similar code

Regards

Mikael Hansson

1 Reply 1

npetrele
Cisco Employee
Cisco Employee

Here's a way to do step 1 with executeSQLQuery:

select device.name from device,numplan,devicenumplanmap,callforwarddynamic

         where numplan.dnorpattern = "<the dn>" and

         callforwarddynamic.cfadestination is not null and

         callforwarddynamic.cfavoicemailenabled = "t" and

         devicenumplanmap.fknumplan=numplan.pkid and

         callforwarddynamic.fknumplan=numplan.pkid and

         devicenumplanmap.fkdevice=device.pkid

Unless I'm misunderstanding your goals, the rest should be pretty straightforward, I think.

Some people prefer:

         where numplan.dnorpattern like "<the dn>" and