1

I would like to consolidate the case types that I have created for CiviCase.

Is there a way to merge two or more case types into a broader category so that the cases once assigned to these more narrow case types can assume the new, broader case type?

2
  • How many cases are we talking about converting?
    – Coleman
    Mar 10, 2016 at 22:35
  • We currently have 21 case types. We want to reduce this number to 9 by deleting a few and combining the rest. Some of the new case types we want to create may incorporate up to 3 existing case types.
    – Leslie
    Mar 10, 2016 at 23:21

1 Answer 1

3

I don't think there's a way in the user interface but if you're comfortable with directly accessing the database and don't need to update any timelines/activities you can do something like:

UPDATE civicrm_case SET case_type_id = CONCAT(CHAR(1), '8', CHAR(1)) WHERE case_type_id = CONCAT(CHAR(1), '1', CHAR(1));

This would take the ones who have case type 1 and convert them to 8. You'd have to look and see what the existing numbers are:

select ov.label, ov.value from civicrm_option_group og inner join civicrm_option_value ov on (ov.option_group_id = og.id and og.name = 'case_type');

And of course do this on a test site first, and make a backup.

3
  • Sounds reasonable.
    – Leslie
    Mar 11, 2016 at 1:14
  • If I use PHPMyAdmin, where to I plug in the above script? Or do I use another program?
    – Leslie
    Mar 11, 2016 at 1:15
  • You can do this with any program that allows you to access the MySQL database (including the command terminal) but certainly with PHPMyAdmin! Mar 11, 2016 at 10:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.