Cisco Support Community

On the Cisco CallManager 5.x, if a deleted Hunt Pilot number is added in order to be used as a directory number, the "Add failed. java.sql.SQLException: Could not insert new row - duplicate value in a UNIQUE INDEX" error message appears

Core Issue

After the Hunt List is deleted, the Hunt Group Pilot Directory Number (DN), information remains in the Cisco CallManager database. This causes problems with the dial plan and the DN cannot be reused.

The same DN shows up as an orphaned Hunt Pilot directory number when searched through the Route Plan Report in Cisco CallManager Administration.


This issue is documented in Cisco bug ID CSCsg05755, which is a duplicate of Cisco bug ID CSCsf12158. In order to resolve this issue, complete this workaround:

  1. SSH login to the Cisco CallManager Publisher server with the use of the OS Platform login credentials.

  2. At the prompt, type this without the angular brackets:

    run sql select pkid, tkpatternusage from numplan where dnorpattern=''

  3. Record the pkid, and type:

    run sql delete from numplan where pkid='         '