Skip to Content
Author's profile photo Michael Vollmer

ChaRM Framework: An Overview of Existing Consistency Checks

In Change Request Management, the ChaRM Framework is some kind of toolset which provides actions and consistency checks which can be assigned to a user status so they get executed. As customer you copy the standard transaction types to the customer namespace and of course all of the ChaRM Frameworks actions and consistency checks assigned get copied.

But what if you as customer want to change the process and adapt it to your need ? Have I to change the assignment of consistency check to another user status? What are they used for?

Documentation of the ChaRM actions and consistency checks is pretty spare in IMG. This article gives an overview over the existing Charm consistency checks.

Some explained consistency checks require a more-in deep explanation. I have tried to give some more hint with an example describing how it is used in the standard process.

As this is a lot of work as you can imagine, I will start with the consistency checks customized and assigned in the SAP standard transaction types first.

The list covers the currently assigned ChaRM consistency checks of the standard transaction types.

  • Request for Change (SMCR)
  • Urgent Change (SMHF)
  • Normal Change (SMMJ)
  • Defect Correction (SMTM)
  • Administrative Change (SMAD)
  • General Change (SMCG)
  • Change Cycles (SMMN, SMMM, SMDM)

But the goal here is to provide a complete list afte a time.

If you find errors and have other comments, just get in contact :-).

By he way, the overview of the ChaRM actions is available here: (http://scn.sap.com/community/it-management/alm/solution-manager/blog/2013/05/08/charm-framework-an-overview-of-actions)

Best regards,

Michael

List builds up on ST 7.10, Support Package 8.

ChaRM consistency

check name

The consistency check checks

Relevant and customized for Detail           
0YES Internal use SMMM, SMMN, SMDV
ALL_TASKS_RELEASED …if all tasks of the original transport belonging to the change document are released SMMJ, SMMJ
ANY_CHANGES …if there are changes done, meaning if the transport belonging to the change document has objects on the piece list SMHF, SMMJ, SMTM
APPROVER_FILLED …if the approver in the approval steps of the approval procedure have valid partner functions and partner id’s assigned SMCR This consistency check is new with ST 7.10, Support Package 8
BO_LINKS_COMPLETE …if the current change document has all related documents (task list and change cycle) links assigned. SMMJ, SMTM, SMAD
CHECK_ACTION_PHASE …if the ChaRM actions customized to the current user status are allowed in the current phase of the assigned phase cycle SMMJ

This depends on a special customizing relvant to the phase controller.

The phase controller checks for all participants if the action is allowed

to be executed. Participants are f.e. the CRM document, the task list,

QGM integration, etc.

CHECK_IN_AND_OUT …if solution objects are checked out currently SMCR, SMHF, SMMJ, SMTM, SMAD, SMCG The solution objects are displayed in the ‘Solution’ assignment block
DGP_CHECK_OK …if unapproved downgrade protection conflicts exist SMHF, SMMJ

The downgrade protection conflicts can be approved in the ‘Downgrade

Protection’ assignment block.

FOLLOW_ON_GEN_OK …if the Request for Change has all information to create the follow-on change documents SMCR

The check includes if the ‘Project’ field in the detail assignment block is

filled (note that General Changes do not need that), if the scope has an

entry and if the change category and ibase information exists. In case it’s

an General Change, all iBases can be assigned, for the Administrative

Change an iBase of the productive and quality client is valid. For the Normal

and Urgent Change we need an iBase of an productive client. All iBases

(except for the General Change) have to point to systems in the logical

components of the assigned project.

IB_SYST_CHK …if the change document has an iBase assigned SMCR, SMTM
IMPORT_INTO_PROD_OK …if the import of the original transport request of the Urgent Change has been successfully imported into the productive client SMHF
IMPORT_INTO_TEST_OK …if the import of the original transport request of the Urgent Change has been successfully imported into the test client SMHF
IMPORT_OF_COPIES_OK …if the import of the original transport request of the Normal Change has been successfully imported into the productive client SMMJ

The Normal Change does not transport the original transport into the

test client when the change should to be tested. It always transports

a ToC (Transport of Copies) from the original transport request.

MAINT_INST …if the Maintenance cycle for the production system is open SMHF, SMMJ, SMAD
NO_BUSINESS_PARTNER …if the current user has a business partner SMHF, SMMJ, SMTM, SMAD, SMMM, SMMN, SMDV
NO_CHANGES …if the transport of the change document does not contain objects. No changes were made (empty piece list) SMHF, SMMJ, SMTM
NO_CRTCL_OBJ There are no critical objects on the piece list of the transport belonging to the change document SMMJ
PREDOC_CAN_BE_SET …if the user status of the predecessor can be changed SMCR, SMHF, SMMJ, SMAD, SMCG

Meaning if the predecessor document is not locked (edit mode).

Example: An Urgent Change is set to ‘Imported to Production’.

In this user status, the ChaRM action ‘SET_PREDOC’ is executed.

In IMG activity ‘Make Settings for Change Transaction Types’, area

‘Specify Status Setting for Predecessor Documents’ it is customized

that the Request for Change (SMCR) shall be set to user status ‘Implemented’. PREDOC_CAN_BE_SET checks if that can be done

PRELIM_PRD_NOT_IMP …if the preliminary imports have not been imported into the productive system SMMJ For more information about the preliminary import process: http://scn.sap.com/community/it-management/alm/solution-manager/blog/2012/06/19/how-to-integrate-the-preliminary-import-functionality-for-customers-with-existing-and-changed-normal-change-user-status-profile-in-solman-71–sp5
PRELIM_TR_IN_PRD_BUF …if the transport is already in production system import buffer SMMJ
PREP_FOR_PROD …if the import into the pre-production client is done SMHF Specific for the Urgent Change
PRODUCTION_IMPORT_OK …if the import into the production client is done SMMJ Specific for the Normal Change
PROJECT_ASSIGNED …if the Request for Change needs the project field in the ‘General Data’ assignment block filled SMCR

In case of only ‘General Changes’ in the scope we do not

need project information

RETRO_TRANS …if all transports of a change document have been retrofitted SMHF, SMMJ, , SMMM, SMMN
RFC_DEST …if the RFC connection to the ChaRM system exists accordingly SMHF, SMMJ, SMTM, SMAD, SMMM, SMMN, SMDV
SAME_USER

Specifies the business partner to which the system compares the business
partner of the current user (defined in SY-UNAME). If the two business partners
are the same, the consistency check is not fulfilled.

SMHF, SMMJ, SMTM, SMAD

The relevant customizing iIMG activity for SAME_USER is

‘Make Settings for Change Transaction Types’, area  ‘Specify Partner

Assignment and Check’.

Example: The Urgent Change specifies that the user who sets user status

E0005 (Successfully Tested) is written in the partner function ‘Tester’ and

the developer is not allowed/should not do it(column 4-Eyes Principle…).

At the same time the user who sets user status E0004 ‘To Be Tested’ before

is written into the partner function ‘Developer’. This customizing ensures with

the SAME_USER consistency check customized with an cancel that the

developer cannot set the user status ‘Successfully Tested’, meaning he cannot

develop and test successfully.

Please note that the screenshot with reworked column texts is taken from a

coming Support Package.

Same User 2.png

SUB_ITEMS …if the dependent follow-on documents have a sufficient user status in respect of the user status set in the current change document SMMN, SMDV

This consistency check is mainly used for the change cycles. It checks if the

change documents linked to the change cycles have a specified user status

(fulfill the customized user status in IMG activity ‘Make Settings for Change

Transaction Types’, area ‘Specify Required Status Values for Successor’) to

change the phase.

For example the Maintenance Cycle is only allowed to go into phase ‘Go Live’

(E0006) in case all defect corrections are ‘Confirmed’, all Urgent Changes have

status ‘Authorized for Production’ and the Normal Changes are ‘Successfully Tested’:

SUB.png

SYSTEM_EXIST …if the scope is filled with at least one item which has the change category and iBase information maintained SMCR
TASKLIST_ACTIVE …if the task list status is active SMHF, SMMJ, SMTM, SMAD

An example of an active task list.

/wp-content/uploads/2013/05/active_217304.png

TASKLIST_CLOSED …if the task list status is completed SMHF

An example of an completed task list.

/wp-content/uploads/2013/05/closed_217305.png

TR_REQUEST …if all transport request belonging to the change document are released or deleted SMHF, SMTM
TWB_TEST_OK …if a test plan is attached and the test status is ok SMMJ

SAP delivers the standard BadI implementation

‘AGS_CHARM_TWB_STATUS_CHECK’ which checks this but

customers can implement their own checks via BADI ‘BADI_TWB_CHECKS’.

Assigned Tags

      18 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Wence Lacaze
      Wence Lacaze

      Hi Michael,

      Excellent document!!! thanks for share!!!

      Wences

      Author's profile photo Raquel Pereira da Cunha
      Raquel Pereira da Cunha

      Hi Michael,

      finally a very clear explanation of what each of the consistency checks means and to which change documents they are related to. Thank you for sharing.

      I still would like to know if we will be able to use SUB_ITEMS for change documents too instead of only cycles. I had to implement via BADI and new Z condition check a way to control the status changes of an RfC depending on the status of the change documents created by it. In this use case I needed to create new customer status in the RfC and they should only be possible when specific customer status of the change documents were reached. Isn't it possible to have the condition check SUB_ITEMS implemented in class CL_CHM1_INSTANCE (same as PREDOC_CAN_BE_SET) and allow it to be used for all change documents? We already have an IMG activity for configuring that, we only need the existing code to be available.

      Best regards,

      Raquel

      Author's profile photo Michael Vollmer
      Michael Vollmer
      Blog Post Author

      Hi Raquel,

      thanks for your comments. I checked the condition SUB_ITEMS. At a first look, I would say it should work without issues to move it to the super class. But before this is officially given to all customers, it should be tested and for us, it's a Prio low so I won't have the capacity to build up a scenario. Maybe, because the change is just copy/paste, I could create a pilot note for your customer if he is willing to test it, so he gets back to standard. And if this is tested, we can put it into the next release. What do you think?

      best regards,

      Michael

      If this would be ok, just mail me the details or create a Prio low message and forward it on my name. The customer has to agree to comment out the customer implementation BadI, then.

      Author's profile photo Raquel Pereira da Cunha
      Raquel Pereira da Cunha

      Thank you for the feedback Michael. I will contact the customer and if they agree I will let you know.

      Best regards,

      Raquel

      Author's profile photo Imran Mohammed Gadiwan
      Imran Mohammed Gadiwan

      Hi Micheal,

      Thanks for your detailed comments on these existing checks. Can we customize these checks by creating a copy of std checks. I am in particular referring to "Check_Action_phase" where in i want to restrict certain actions to be performed only in certain phase of the project cycle. Currently, with the phase of cycle being "In development with release" i am able to process the CD until "Successfully Tested" status. I want to control this and restrict the actions only to be performed during each phase.

      Is it possible? if yes, will the existing check works or do we need to create a new one.

      Please suggest.

      Regards,

      Imran

      Author's profile photo Louis Nicolas Arson
      Louis Nicolas Arson

      Hi, I have exactly the same requirement, and don't know where to find the customizing point associate. For, certain project, I would like to avoid validate the change (means released the original TR) until we are in "preparation of Golive" Phase on the project.

      As I remember, there is some action allowed/not allowed depending on the project phase (SMDV and SMMJ)... but I forgot where is it !?

      Regards,

      Author's profile photo Michael Vollmer
      Michael Vollmer
      Blog Post Author

      Hi Imran,

      you could copy the code but not directly copy the check itself. Customer checks have to be implemented separately.

      best regards,

      Michael

      Author's profile photo Former Member
      Former Member

      Hello Micheal,

      I am stuck with the following requirement...can you throw some light on how to achieve this requirement.

      I have the following requirement.

      In a normal change, on change to a particular status, say(Set to In Development) the action behind 'Add Attachment' button must be triggered and the attachment uploaded has to be reflected in the 'Attachments' section.

      In short, I must ensure that there is an attachment in the 'Attachment' section for particular statuses.

      Is there a way to get this done.

      Thanks,

      Greg

      Author's profile photo Michael Vollmer
      Michael Vollmer
      Blog Post Author

      Hi Greg,

      just implement a ChaRM consistency check which checks if the document has an attachment. You can then customize it with a warning message to the 'In development' status, so that it reminds the user in case there is no attachment. And customize it to the next status with 'Cancel', so it resets the user status back to 'In development' in case there is no attachment.

      Hope that helps,

      best regards,

      Michael

      Author's profile photo Former Member
      Former Member

      Hi Micheal,

      Thanks for your response. I am very new to SolMan and would be greatful if you can provide some more inputs.

      I will find the way to check if a document is attached in the attachment tab but my requirement is such that different documents must be mandatory for different status. ie...Tech spec must be mandatory when status changes to 'Set to code review', code review checklist must be mandatory for 'To be Tested' and so on....so do you mean that for first status, I must check if the number of attachment = 1 and for the next status, the no. of attachment = 2, and if it fails, cancel the status update and revert it to the current status.

      Am I right are am I missing something?

      Also would be great if you can help me with the way to check for the document in the attachment tab using consistency check.

      Hope I must implement SOCM_CHECK_CONDITION badi.....but not sure how to read if there is a document in the attachment tab.

      Thanks for the help.

      Best Regards,

      Greg

      Author's profile photo Michael Vollmer
      Michael Vollmer
      Blog Post Author

      Hi Greg,

      sure you should use SOCM_CHECK_CONDITION badi. The rest of your questions are design questions your developer (or you have to clarify).

      You can read the attachments like this if you have the GUID.

      CALL FUNCTION 'ICT_READ_ATTACHMENTS'

             EXPORTING

               i_crm_id     = lv_guid

             " I_IDS_ONLY   = abap_true

             IMPORTING

               e_t_document = lt_docs

               e_t_url      = lt_urls.

      How you check it is design. F.e. the you could agree that the documents follow a specific naming convention. Which means a document containing the string 'SDD' is a technical design document, etc. You might as well implement a customizing table where you define the relevant strings of the attachments for the relevant user status and transaction types ;-). I believe the pure number of attachments is no good criteria,

      best regards,

      Michael

      Author's profile photo Former Member
      Former Member

      Many thanks Michael....I will try implementing this!

      Just a thought.....can the consistency check be applied for button click too.....Like if there is an active TR already available, the user must be restricted from creating another TR. he must be able to create only if all the TRs are released.

      Best Regards,

      Greg

      Author's profile photo Former Member
      Former Member

      That worked as desired! Many Thanks Michael!  🙂

      Best Regards,

      Greg

      Author's profile photo Former Member
      Former Member

      Just to add, we have not implemented Document Management......We are only using the 'Attachments' section.

      Best Regards,

      Gregory

      Author's profile photo Riccardo Escher
      Riccardo Escher

      Hi, very nice blog, thanks.

      I use this way to point out a IMHO unhappy configuration for the checks in the SMCR and therefore in the copied transaction types.

      SAP skilled users do all right :-). But we rolled out YMCR and YMCG for the IT Infrastructure, and these skilled admins succeed in creating and approving RfCs with empty or crippled scope assignment blocks. Thus the RfC workflow stops in the status "Approved".

      To avoid this, we added the check SYSTEM_EXISTS also for the status E0012 To Be Approved, thus enforcing a correct scope assignment, because it's the scope which will be approved, or not?

      The destination user status should be empty because there can be two (Validation and Scope Extention)27-02-2015 14-24-21.jpg

      Author's profile photo Tuulia Heikkilä
      Tuulia Heikkilä

      Hello and thank you this very nice information.

      We have business partners which are locked because they don't work any more. Customer want's to lock those and after that change requests are locked too because of message "Business partner is locked". Is there any other possibility to use those business partners and mark them "somehow" obsolete. These business partners has relationship for real person. Anyone any ideas how to handle this?

      Author's profile photo Michael Vollmer
      Michael Vollmer
      Blog Post Author

      Hi Tuulia,

      I have some more questions to understand what would be a relevant solution.

      You could maybe check if it is possible to adjust the title of the people from Ms./Mr. to 'Locked'. I would expect that somewhere you can customize titles...

      then instead of the Mr. you would have a (Locked) before. Check how many characters are available.

      Mr.jpg

      Or do you want more to replace the bp's so you can use the change again? Then I would create a PPF action which checks if the document has a locked user  via coding and in case replaces it by a standard user where you report on, so you see all documents which have this user and where you have to do something (assign new valid business partner). The PPF action should log in the text at least which bp was replaced.

      The PPF condition could be that it runs each time (the document is saved). If this makes to much performance, the best way (which I do technically not know where to start here) would to enhance the bp maintenance. If a user is locked a background job or a function module in new task is started which checks where the bp is used and replaces them.

      Maybe I could help,

      best regards,

      Michael

      Author's profile photo Former Member
      Former Member

      Hi Michael,

      I'm confused

      001.PNG

      002.PNG

      SP 12