Oracle Endeca 11.x : How to Setup Precedence Rules?
A Precedence Rule provides a way to hide the display of dimensions until someone click a dimension or a particular navigation state. Precedence rules are defined in terms of a trigger dimension or trigger dimension value and a target dimension. A user's selection of the trigger dimension value exposes the previously unavailable target dimension to the user.
There are two types of precedence rules, standard and leaf:
1. The standard type means that if the navigation state contains the trigger dimension value or any of its descendants, then the target dimension value is displayed.
2. The leaf type works similarly, but only considers leaf dimension values (those with no children) as possible triggers.
Example:-
1. Display Category after selecting a department. This rule will show Category dimension after clicking of any department
Open <<Endeca_APP>>/config/index_config/index-config.json
and add following rules under precedence rule section
"Rule-name-1" : {
"targetDimension" : "product.subCategory",
"triggerDimension" : "product.department",
"isLeafTrigger" : false
}
2. Clicking on Category like
Shoes than display Shoes Size.
Clothing than Clothing sze
add following extra rules under precedence rule section. This rule would be triggered based on specific refinement.
"Rule-Name-2" : {
"triggerDimension" : "product.subCategory",
"triggerDimensionValueSpec" : "Shoes",
"targetDimension" : "product.shoeSize",
"isLeafTrigger" : true
}
Note :- triggerDimensionValueSpec accepts dimension value spec not the N-value.
Run the following command from apps control after making changes in index_config.json
./index_config_cmd.sh set-config -o system -f <<File_Path>>/index-config.json
There are two types of precedence rules, standard and leaf:
1. The standard type means that if the navigation state contains the trigger dimension value or any of its descendants, then the target dimension value is displayed.
2. The leaf type works similarly, but only considers leaf dimension values (those with no children) as possible triggers.
Example:-
1. Display Category after selecting a department. This rule will show Category dimension after clicking of any department
Open <<Endeca_APP>>/config/index_config/index-config.json
and add following rules under precedence rule section
"Rule-name-1" : {
"targetDimension" : "product.subCategory",
"triggerDimension" : "product.department",
"isLeafTrigger" : false
}
2. Clicking on Category like
Shoes than display Shoes Size.
Clothing than Clothing sze
add following extra rules under precedence rule section. This rule would be triggered based on specific refinement.
"Rule-Name-2" : {
"triggerDimension" : "product.subCategory",
"triggerDimensionValueSpec" : "Shoes",
"targetDimension" : "product.shoeSize",
"isLeafTrigger" : true
}
Note :- triggerDimensionValueSpec accepts dimension value spec not the N-value.
Run the following command from apps control after making changes in index_config.json
./index_config_cmd.sh set-config -o system -f <<File_Path>>/index-config.json
Discussion (2)
Technical questions and architecture discussionsJoin the Discussion