Setting up multiple results for one critical number

For processes that run through a large amount of data, you can create multiple results for one critical number calculation.

Multiple results for an IDO-based critical number

These are the actions required to set up multiple results for an IDO-based critical number:

  • Build an IDO-based critical number.

    See Creating Critical Numbers.

  • To generate multiple results, select values for the Group By or Date Property fields.

Multiple results for a stored procedure-based critical number

Generating multiple results with stored procedure-based critical numbers is more complex. The preconfigured AR Age critical number is an example of one record that can be set up to create hundreds of other numbers, when programmed correctly.

These are the actions required to set up multiple results for a stored procedure-based critical number:

  • Build the stored procedure-based critical number.

    See Creating Critical Numbers.

    Note:  Consider using static parameters to set up the Goal Value and Alert Value, and other settings for each record you want to create. For example, the AR Age number uses Alert-1, Alert-2, Alert-3€¦.Alert-7, Goal-1, Goal-2, Goal-3...Goal-7, Bucket-1, Bucket-2...Bucket-7. This ensures that the values are not hard-coded and the end-user can change them without modifying the stored procedure.
  • Write your routine as you do others, but instead of assigning only @Actual, you must create all the #tt_cr_nums records that you want to include. Call the standard procedure WBLoadCrAddSp to accomplish this:
    
    CREATE PROCEDURE dbo.WBLoadCrAddSp (  @KPINum      WBKPINumType, @Category    WBCategoryType
    , @Id          nvarchar(500)
    , @Amount      AmountType
    , @Description NVARCHAR(500)
    , @GoalVal     AmountType = NULL
    , @AlertVal    AmountType = NULL
    , @MessageTxt  Infobar = NULL
    , @GoalOper    WBOperatorType = NULL
    , @AlertOper   WBOperatorType = NULL
    ) AS
    

Notes

Because the results have the same critical number, set the Id parameter to distinguish the numbers. The Id is passed to the drilldown so you can view the appropriate information.

GoalVal and AlertVal are optional. The system uses the values from the Critical Number Setup form if you do not override them.