zoukankan      html  css  js  c++  java
  • SAP CRM订单状态管理的一些重要的数据库表

    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

    要获取更多Jerry的原创文章,请关注公众号"汪子熙":

  • 相关阅读:
    单位矩阵
    向量的内积(也叫点积)
    svm
    vue.js 中this.$router.push()的使用
    Spring Bean 的加载过程
    Solr是什么?
    Servlet中如何获取用户提交的查询参数或表单数据?
    Redis面试题大全含答案
    Overload和Override的区别。Overloaded的方法是否可以改变返回值的类型?
    抽象类(abstract class)和接口(interface)有什么异同?
  • 原文地址:https://www.cnblogs.com/sap-jerry/p/13545025.html
Copyright © 2011-2022 走看看