.. _ini-purge-tool:

INI purge tool
----------------------

.. _21.1|VOSS-832:

Number Inventory entries can be deleted in bulk by using the INI Purge Tool.
High level administrators with access to the view called ``INI_Purge_Tool_View``
can expose this tool for user by updating menu layouts and access profiles for
administrators.


.. important::

   This Tool has been designed to remove DNs *without* taking into account the Status of the DN,
   so that DNs can be completely removed and then redeployed. In normal circumstances you cannot
   delete a DN if it is in use by a Phone.

   For example, DNs may have been deployed incorrectly at Site level instead of at
   Customer level. You can therefore "Purge" all the DNs entries at the Site and re-add them at Customer
   level. The DN Audit Tool then needs to be run to update the DNs to the correct Status.




.. rubric:: Using the INI purge tool

1. Navigate to the required hierarchy and select the **INI_Purge_Tool_View**.
2. From the **Ini Purge Tool View** form, an **INI Option** can be selected.
   
   .. note::

      Special characters in INI entry numbers are also supported,
      for example ``1*6010``. 

   The drop down list options are:

   * **All INI at Hierarchy**: applies to all INI numbers at the current hierarchy.
   * **Range of INI Entries**: exposes **Range Start Number** and **Range End Number**
     drop down lists to choose the range.
   * **Picked List of INI Entries**: exposes **Picked INI Entries**
     transfer boxes: **Available** and **Selected**.
     to choose a selection of entries.
   * **Specific INI Entry**: provides a **Specific INI Entry** drop down
     list to select a single entry.
3. Click **Save** to carry out the purge task.

Inspect the log from the **Transaction** menu - the **Action** carried out 
is a Bulk Delete from the Internal Number Inventory. Deleted numbers are
removed and are not available from the **Internal Number Inventory** list view.

.. note::

   Where more than 1000 entries are to be purged, the transaction will show
   sub-transactions deleting the entries in chunks of 1000. A successful sub-transaction
   then shows the message per chunk: "[1000 / 1000] were deleted successfully".


