Symptom
- Is there a way to trace a Business Rule?
- How to check if a Business Rule has executed properly
- How to check the rule execution steps when any rule is executed
Image/data in this KBA is from SAP internal systems, sample data, or demo systems. Any resemblance to real data is purely coincidental.
Environment
SAP SuccessFactors Employee Central
Resolution
Creating a Rule Trace is a great way to troubleshoot Business Rules to analyze errors.
Each time a specific rule is triggered, a log is created to show that how the system validates and possibly sets that rule
To create a Rule Trace, do the following:
- Go to Admin Centre > Business Rule Execution Log > Create New > Rule Trace
- Provide a Code and a Name
- This can be any naming schema as long as you are able to recognize it afterwards to retrieve the log trace after execution
- Start date will use the same time as the Server Time
- Note: It is best practice to get a time stamp from the system to ensure that you are selecting the proper dates and select the End Date as one day ahead
- Click on your name menu at the top of the page
- Click on show version information
- This will tell you the date of the server
- If you do not select the proper date the log returns empty results
- Note: It is best practice to get a time stamp from the system to ensure that you are selecting the proper dates and select the End Date as one day ahead
- Select the Login User
- Note: The Login User field will represent the user which executes the transaction (Note: this is the user you proxy and not the login user).
- This will either be the login user or if you are proxied as another user to trigger the transaction, put the proxy user instead
- This can be any system user that is active including an Admin, Manager, or other employee
- For Provisioning jobs, the "Login User" must be the Job Owner of the Job
- In case the user has no First and Last Name maintained within Personal Information, it will not be displayed when searching the "Login User"
- On the Rules to be Logged section, there are two ways to execute the Rule Trace:
- If "Rules to be Logged" is empty the system will gather all the associated rules with the transaction
- If you input a rule at the Rules to be Logged section, the system will only retrieve the logs for the selected rule
- Select the trace mode Complete or Short (What is Short Trace mode? Check this Short Rule Trace | SAP Help Portal).
- Perform the transaction which is believed to trigger the rules.
- Click on download and view the steps performed by the rule in the Comma Separate Value (CSV) file.
Note:
- If you see the downloaded CSV file is empty, then the rule has not triggered for the transaction. If a rule fails for any reason, this information will also be available inside the Rule Trace CSV file
- You can set up a rule trace for a maximum time period of 2 days. This is to ensure that only new and up-to-date traces are active in the system at any particular time.
Post- release: 1H2024
Rule trace threshold Error: The maximum amount of 50 rule traces has been reached. This means that you have to delete old rule traces before creating a new one to stay under the threshold.
FAQ - Additional Information
Q) Where can I get information on this from the Guide?
A) Handbook: Implementing Business Rules in SAP SuccessFactors
Chapter:Creating Business Rule Execution Logs
Q) Can we use Diagnostic Tool instead of rule trace?
A) Some scenarios are supported in Diagnostic tool. This tool provides a detailed and visual presentation on how the rules impact different portlets, fields, etc. It's easier to understand the results in Diagnostic tool compared to Rule Trace.
KBA: 3468733 - Diagnostic Tool for Employee Central save transactions and workflows
Handbook: Using the Diagnostic Tool
See Also
Keywords
SF, success factors, EC, rule isn't working, logging, empty, missing, rule trace, business rule execution log, execution log, log, trace, file, export, track, FAQ, PLT business rules, The maximum amount of 50 rule traces has been reached. This means that you have to delete old rule traces before creating a new one to stay under the threshold , KBA , LOD-SF-EC-JOB-RUL , Job Info Business Rules , LOD-SF-EC-ADM , Admin Tools (EC Core only) , LOD-SF-EC-CMP-RUL , Business Rules , LOD-SF-MDF-RUL , Custom Oject based Business Rules , LOD-SF-RCM-RUL , Recruiting Rule Issues with MDF Platform , How To
SAP Knowledge Base Article - Public