I have created this document in order to help the customer with one of many sub scenarios provided by Process Control Business Rules. My objective is to create one document for each sub scenario. This is the first one.
Before starting creating Data Sources and Business Rules, you need to check parameter for table logging in RZ11. You can specify specific clients for table logging or set the default option to ‘All’. Check SAP note 1653464 for further information on performance.
When setting continuous monitoring, you must create a Data Source.
Why creating a Data Source?
The data source created is usable for many business rules. The data source is where system is going to obtain monitored data.
Supported Sub-scenarios:
- SAP Query
- BW Query
- Process Integration
- SoD Integration
- Configurable
- Programmed
- Event
- ABAP report
- External Parter
In this tutorial we only will see the Configurable Sub-Scenario (Highlighted in Gray).
Creating a Data Source:
Filling out the General Tab:
![DS1.JPG]()
Object Field:
In this example, I selected to monitor changes in HRP1000. I have selected some tables Field to lookup.
I cannot find any information related to this table.
HR tables are not supported in a Configurable scenario. You can include HR tables in the configurable scenario at your own risk by There is a work around. You can maintain the HR/PA table name in the table /GRCPI/GRIASPEC and can be used in Configurable scenario. However SAP will not hold any responsibility for this work around and it is not recommended. Customer at their own risk can implement this work around. We need to check another table to lookup.
LFA1 (Vendor master table) is a standard SAP Table.
![DS2.JPG]()
Explanation of Related Table Lookup:
The Reference or Dependent tables option define the direction of the relationships.
Dependent tables are those which refer to (as foreign keys) the key fields of your main table (primary keys), while reference tables are the opposite — they hold the primary keys to which your main table refers as foreign keys. You can join multiple related tables together in such a compound data source, with the constraint that the join conditions are restricted to being equality relationships between like-type fields. For the most part, it is expected you will join primary keys to foreign keys. PC 10.0 looks up known relationships from the data dictionary and pre-populates the join conditions area as you go.
When creating a Join condition in data sources, you may consider the following:
- If the join condition will make the result table retrieve data (according to the cause mentioned in KBA 2177348);
- Maximum number of related tables is 5 (five);
- Some fields in the join condition are not appearing (See the explanation in the resoltion section of KBA 1970160);
- If duplicated tables are created when adding the related tables in the join condition, SAP note 1880242 must be implemented.
Next step is to perform an ad-hoc query to check whether the table data is being retrieved.
![DS3.JPG]()
Retrieved results successful. Meaning that the connection is okay.
In the connectors tab, you can check the connectors assigned to this Data Source. You can have multiple Connectors assigned to one Data Source.
![DS4.JPG]()
The Data Source must be active to be available in the Business Rule.
![DS5.JPG]()
Creating a business rule:
Select the Data Source created and press start.
![BR1.JPG]()
I chose the data I have selected in the Data Source. Here you can choose the fields you want to monitor:
![BR2.JPG]()
In the filter criteria, I only included the Name of person who Created the Object:
![BR3.JPG]()
For the filter values, I chose ZHAOBR (include this range). I just want to include changes made by this user.
![BR4.JPG]()
In the deficiency criteria, a handler must be selected in order to get changes from the target system. The table responsible for transport changes is SCU3.
![BR5.JPG]()
Once selected, the fields must be shown in the Field Description.
If the fields are not available user needs to check in the target system whether or not the table LFA1 (table used in this example) is active for log changes.
Go to SE11 and type the table in the Database table field:
![se11.JPG]()
Go to technical settings of the table:
![se112.JPG]()
Enable Log Data Changes:
![se113.JPG]()
Check whether SCU3 is logging LFA1 table after the changes:
![scu3.JPG]()
After this procedure if you still cannot see the deficiency fields check your GRCPINW support package level. An enhancement was done for capturing table change log directly from SCU3. Apply SAP note 1796052 if you are under Support Package 10 of GRCPINW.
Now, if we return to the Business Rules, the field descriptions are activated.
![BR6.JPG]()
Conditions and Calculations
In this steps you can insert additional conditions to the Business Rule (BRFPlus). You can totally customize the BR according to your company needs.
Output Format
In the output format you can defined how the business rule will be shown.
Technical settings:
These settings basically affect the execution and performance of monitoring. It is always a best practice to test the performance of rules before transporting to production.
1. Calculate deficiency -> Remotely
It is used in the same way as PC 3.0. The job will collect data and apply the rule only on the returning data which is defined as deficient by the ERP. When the data volume is huge, this method will help to reduce the retrieving data.
2. Calculate deficiency -> Locally
This is used for almost all the sub scenarios. It analyzes the data on Process Control side. Rules are applied on the Process Control side as well.
3. Communication mode -> A sync.
Process Control will perform a job steps (execution of a Business Rule) via RFC to the ERP system and it will be executed in background mode. When the execution is finished, RTA sends the result back via RFC to Process Control. It is a two way communication.
4. Communication mode -> sync
Most of the sub scenarios use this. It means that when a Job step is executed, the Work Process waits the result from the RFC call and processes it. In most of the cases, this is used to calculate deficiencies locally.
5. Change log type
Here you can include the change types you want business rule to capture.
Ad-hoc query
Here you will test your business rule against all the criteria you have established.
![No data found.JPG]()
The message is not an error. It means that the information for that timeframe was not found for that connector. Changing the timeframe to 2012 for example, I can find results.
![adhoc.JPG]()
Based on my conditions and filters, the results are showing correct.
Checking SCU3:
![scu32.JPG]()
I Can see the same results.
After these steps, rules must be assigned to controls.
The results will only be found according to the deficiency criteria. Other fields will not be taken into consideration.
If you are familiar with debugging, you can debug the ad-hoc query to check the results at code level by following the steps in the following wiki: