Skip to Content
I record down my self study notes here in order to be used in the future.
TJ01: Business Transactions definition
TJ02: System status definition. For some of entries in this table, the corresponding constants are defined in include CRM_STATUS_CON
TJ03: status object type definition. Storage table for tcode BS12, see screenshot below:
TJ04: define initial status for system object. For example, I1002 ( open ) is defined as initial status for status object COH ( CRM Order Header ). Due to this setting, every time you create an order, it always has open as initial status.
TJ05: Permitted transactions per object type
For example, status object COH has totally 369 permitted business transactions. The system status bound with a unpermitted business transaction will not appear in status drop down list in WebUI. See this blog How is status drop down list entry generated in Order detail page about detail filtering logic.
TJ06: System statuses set/deleted by process
For example, the following report checks whether a given user status is actually mapped to Completed system status I1005 or not.
REPORT order_is_status_completed.
PARAMETERS: t_type   TYPE crmd_orderadm_h-process_type OBLIGATORY DEFAULT 'OPPT',
            i_status TYPE crm_j_status OBLIGATORY DEFAULT 'I1001'.
DATA lt_sys_stat          TYPE TABLE OF tj06.
DATA lv_status_profile      TYPE j_stsma.

SELECT SINGLE user_stat_proc FROM crmc_proc_type INTO lv_status_profile
  WHERE process_type = t_type.
CALL FUNCTION 'CRM_WAP_GET_OPP_POSSIBLE_STAT'
  EXPORTING
    iv_stat           = i_status
    iv_user_stat_proc = lv_status_profile
  TABLES
    et_06             = lt_sys_stat.
READ TABLE  lt_sys_stat WITH KEY istat = 'I1005' inact = abap_false TRANSPORTING NO FIELDS. "check system status is complete
IF sy-subrc = 0.
  WRITE:/ 'This status is Completed Status'.
ELSE.
  WRITE:/ 'This status is NOT Completed Status'.
ENDIF.
Can you tell the answer that for status profile CRMOPPOR below, which user status is actually mapped to system status I1005?
The answer is COMP ( Completed – Jerry ), since it is assigned with business transaction CCOR,
And there is one entry for CCOR and I1005 in this TJ06 table.
TJ07: Influence of system status on transactions
For example, this entry below means it is not allowed to perform transaction ARCH ( Archive ) if order has status I1002 – Open.
This table is part of storage table for tcode BS22 – maintain system status
TJ21: Permitted object types for status profile
For example, status profile is only allowed for status object type COH.
TJ30: storage table for tcode BS02 – Maintain status profiles
Compare the content of this table with tcode BS02:
CRM_JSTO: assignment of object with its status object type
If you woud like to get a statistics for example which combination of status object and status profile has been used most of the time in your system, you can get the source code of report from my blog A real case to use REDUCE to finish a task in daily work.
For example, the screenshot belows show in my system there are totally 69436 objects which has used object type MPL and empty status profile for status management.
CRM_JEST: object guid and all of its status value
To report this post you need to login first.

3 Comments

You must be Logged on to comment or reply to a post.

  1. Samantak Chatterjee

    Hello Jerry,

    Thanks again for a wonderful collection of the entire set of Status Tables. I would like to recommend another bit to this excellent collection to make it more complete. It would be great if you can also add the list of One Order API’s which helps in reading and manipulating the  transaction statuses.

    For example :

    CRM_STATUS_READ_OW – For reading the business  transaction status

    CRM_STATUS_MAINTAIN_OW – For updating the Business transaction status.

    You can also add the other function modules which will take care of handling the status.

    Best Regards,

    Samantak.

    (0) 
    1. Jerry Wang Post author

      Hello Samantak,

      Thanks a lot for reading. And a good suggestion indeed, since recently in my project I really also need to have a good understanding on those FM you mentioned. I will make a collection if time allows. 🙂

      Best regards,

      Jerry

      (1) 
      1. Samantak Chatterjee

        Hello Jerry,

        Thanks for your reply. I really look forward to see the publication of your research and thanks for taking your time to share the details with other SCN users.  🙂

        In the mean time I will do some deep dive into some of your other blogs.

        Thanks,

        Samantak.

        (0) 

Leave a Reply