Create a New Function

Functions are useful when you need a calculation or process repeated that is accessible by multiple transactions or business rules.  Functions are also beneficial when you are only concerned with the output and result values and not the intermediate values calculated by the function.

 

Function Configuration Standards

Functions are made up of four components.  They are listed below along with a description.

 

 

Steps to Create a New Function

  1. Go to Global Rules Explorer tab.

  2. Right-click on the Functions folder.

 

 

  1. Select New Global Rule for Category Functions.   

  2. Enter a name for your function and select Next.  Function names should always begin with Function- then whatever name you want to name the function.  No spaces are allowed in the function name and you should use camel case.

  3. Functions are always at a global level, you cannot select an override level.

  4. Select Function from TypeCode and then select Next.

  5. Fill out the template information and select Finish.

  6. Configure the function.  Refer to the steps below for more details on configuring functions.
     

Step 3 of Function Wizard

 

Steps to Configure a New Function

  1. Double-click the new function's XML file to open it in the Configuration Area.

  2. Click the Parameters tab.

 

Function Parameters

 

  1. Enter the name of the function.

  2. Enter the return value.  Make sure it starts with the letter r.

  3. Select the Data type.

  4. Click the radio button for Yes or No if function is an array.  

  5. Click Add and double-click in the blank field to enter the input parameters.

  6. Click Add and double-click in the blank field to enter the output parameters.

  1. Click the Math tab and configure the math section.  You can use all functionality available in the MathVariables section of Math with the exception of LOG.  Assignment tags should not be used in the Math section of a function.

 

Note:  Refer to the Math Pane section for additional information on configuring in the Math Pane.

 

  1. Check-in the XML file to save your changes to the database.