In business rules on the Location table, previous is the same as current 


For After business rules on the Location table [cmn_location] table with an order of 100 or higher, "previous" is the same as "current."


Steps to reproduce
  1. Log in to a Fuji instance.
  2. Create a business rule:
    • Table: Location [cmn_location]
    • When: After
    • Update: true
    • Order: 100
    • Condition:
    • Script: gs.log("Contact field has been updated");
  3. Navigate to a Location record.
  4. Update the Contact field.
  5. Navigate to the system log.
    Note that the message was not recorded.

The business rule fails to run because "previous" is the same as "current" and therefore the condition is not satisfied. The problem seems to be caused by the base system business rule named Location - generate full name. As a workaround, change the order of the custom business rule to a value lower than 100 (for example, 90). 

The business rule Location - generate full name also calls HierarchicalReference to generate the full_name on Locations. This performs an update (to generate the full_name for hierarchy location) so previous = current on contract change.

For more information, see Defining Locations in the product documentation.


Article Information

Last Updated:2019-05-21 11:36:50