DQL to uninstall Workflows
- Retrieve the workflow that needs to be uninstalled
SELECT r_object_id, object_name, r_definition_state FROM dm_process WHERE object_name = ‘<Name of Workflow>‘
- Change the definition of the workflow to DRAFT (0 = Draft)
UPDATE dm_process OBJECT SET r_definition_state = 0 WHERE r_object_id = ‘<r_object_id retrieved in step 1>‘
- Change the definition of the activities corresponding the above workflow to DRAFT (0 = Draft)
UPDATE dm_activity OBJECT SET r_definition_state = 0 WHERE r_object_id IN (SELECT r_object_id FROM dm_activity WHERE r_object_id IN (SELECT r_act_def_id FROM dm_process WHERE r_object_id = ‘<r_object_id retrieved in step 1>‘))
- Verify that all activities are in the DRAFT state
SELECT object_name, r_definition_state FROM dm_activity WHERE r_object_id IN (SELECT r_act_def_id FROM dm_process WHERE r_object_id = ‘<r_object_id retieved in step 1>‘)
You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.
Leave a Reply