Question
Rule key missing in Log-RuleUsage(pr4_log_rule_usage) instances
We are trying to build up statistics on rule execution report. Log-RuleUsage(pr4_log_rule_usage) and Log-RuleUsage-Details(pr4_log_rule_usage_details) does have pxUseCount, pxLastUse, pxFamilyName, pxClassName etc fields. From there Rule Name and Rule
Type could be figured out, but if multiple rule exist with same name for same rule type in different Classes and Rule sets it's getting difficult to identify rule uniquely. We are looking forward the way to find out Rule Ins Key. If it could be captured along with other details it would be very helpful.
Basically we are trying to generate a report which will explain which rules are being executed and which are not. If executed then how many times and what was last accessed date time.
Step To Reproduce:
1. Select Log-RuleUsage/ Log-RuleUsage-Details class in App Explorer and click on instances
2. Open any instance from there and take a note on fields like pxUseCount, pxLastUse, pxFamilyName, pxClassName
3. But could not locate Rule Ins Key there
In SMA
1. Click on Advanced > Rule Cache Management
2. Under "Rule Cache Detail" Rule Type and Rule Name input fields are there
3. Once provided Rule pxObjClass and Rule Name and clicked on "Rule Cache Detail" it's pulling out details from Cache along with Rule Ins Key
4. Which table these details are being captured.
5. From Log-RuleUsage we can get Rule Type and Rule Name. Is there any way to get Rule Ins Key from Cache the way it's working in SMA
***Moderator Edit: Vidyaranjan | Updated Categories***
Hi,
From SMA :
Each time you access a rule, it tries to find the entry in cache, if not, it creates an entry in cache, and later on uses that entry , if we try to execute the same rule again .
It pulls the data from the table 'pr_sys_appcache_shortcut' to check if a shortcut has been created for that rule or not.
"SELECT * FROM pr_sys_appcache_shortcut where pzrulename like 'testfa' "
If you run the above query: you will see the rulename, ruletype, class from which it has been accessed and also the pzInskey etc .