SDM: Change Order Cannot be Updated, Cancelled, or Closed

book

Article ID: 196617

calendar_today

Updated On:

Products

CA Service Management - Service Desk Manager CA Service Desk Manager

Issue/Introduction

One change order is stuck in a non-resolved status and the CO needs to be cancelled out. If a user tries to edit this change order, the window simply refreshes. If the user selects, one of the activities from the menu, it opens a new window with the ticket in read-only mode. One can update the status of the ticket using the Edit in List feature, however, this errors if I try to move to Completed or Closed, since the Closure Code field value has not been set (required in this circumstance).

Cause

The given CO had been marked as a template.  Doing a pdm_extract of the Chg_Template table shows all defined templates.

pdm_extract -f "Select id, persid, template, template_name from Chg_Template"

(in the above, the template field maps to the Change_Request ID field)

But if one extracts the given CO directly and reads out the "template_name" value, the affected CO may have such a value in place, despite it not being a template according to the Chg_Template table

pdm_extract -f "Select id, persid, chg_ref_num, template_name from Change_Request where template_name is NOT NULL"

pdm_extract -f "Select id, persid, chg_ref_num, template_name from Change_Request where chg_ref_num = '<CO Ref Num of interest>'"

Environment

Release : 17.2

Component : SERVICE DESK MANAGER

Resolution

Modify the CO Template name directly on the affected CO, blanking it out to see if such an activity will unlock the CO to be cancelled. To do this:

- Backup the CO table itself:

pdm_extract Change_Request > Chg-all.dat

- Backup the specific CO record:

pdm_extract -f "Select * from Change_Request where chg_ref_num = '<CO Ref Num of interest>'" > chg-mod-bkp.dat

- Create a load file that contains basic information about the CO, specifically the template name:

pdm_extract -f "Select id, persid, chg_ref_num, template_name from Change_Request where chg_ref_num = '<CO Ref Num of interest>'" > chg-mod.dat

If your CO ref num was 54321, the command would read as:

pdm_extract -f "Select id, persid, chg_ref_num, template_name from Change_Request where chg_ref_num = ''54321'" > chg-mod.dat

- Edit the resultant chg-mod.dat file and remove the template_name  value in the file.

Original chg-mod.dat file content for CO 54321:

TABLE Change_Request
        id persid chg_ref_num template_name
        { "1234" ,"chg:1234" ,"54321" ,"template1" }

 

Modified chg-mod.dat file content for CO 54321::

TABLE Change_Request
        id persid chg_ref_num template_name
        { "1234" ,"chg:1234" ,"54321" ,"" }

- Save the modified chg-mod.dat file.

- Load the modified file back into the SDM install:

pdm_load -f chg-mod.dat


- Run pdm_cache_refresh on the CO table:

pdm_cache_refresh -t Change_Request

- Check if the CO is accessible to be cancelled on the Web UI.


Additional Information

Please run all pdm_extract, pdm_load, and pdm_cache_refresh commands on a testing SDM Server before doing so in production and make sure all backups of the environment have been performed prior to making the changes.