Automating Decisions with Decision tables
Archived
2 Tasks
10 mins
Scenario
An organization is launching an application that facilitates loan requests. Customers initiate a loan request and enter their credit score and loan amount. Configure a decision table and declare expression, so that the loan rate is determined automatically based on the credit score and loan amount the customer enters. Use the values in the following table to configure your decision table:
Credit score > | Loan amount > | Return | |
---|---|---|---|
if | 800 | 50000 | .0225 |
else if | 800 | 0 | .0200 |
else if | 700 | 50000 | .0325 |
else if | 700 | 0 | .0275 |
else if | 200 | 50000 | .045 |
else if | 200 | 0 | .0425 |
otherwise | .07 |
The following table provides the credentials you need to complete the challenge.
Role | User name | Password |
---|---|---|
Application Developer | author@loans | pega123! |
Note: Your practice environment may support the completion of multiple challenges. As a result, the configuration shown in the challenge walkthrough may not match your environment exactly.
Challenge Walkthrough
Detailed Tasks
1 Configure the Borrower risk adjustment decision table
- From the navigation pane of Dev Studio, click App.
- Right-click LoanRequest and click Create > Decision > Decision Table.
- In the Label field, enter Borrower risk adjustment table.
- Click Create and open to create the decision table.
- Click the first heading cell to specify a condition. The Select a Property window is displayed.
- In the Property field, enter or select .CreditScore.
- Click the Use Operator drop-down and select >.
- Click Save.
- In the Credit score column, click the empty cell to enable the decision table menu options.
- Click Insert Column After to add a column after Credit score.
- Click the new heading cell to specify a condition.
- In the Property field, enter or select .LoanAmount.
- Click the Use Operator drop-down and select >.
- Click Save.
- In the if row, click an empty cell, and then click Insert Row After five times to add five else if rows.
- Click each cell in the decision table and enter the following values:
- Click Save to save the decision table.
2 Configure the Loan rate declare expression
- From the App Explorer, right-click LoanRequest and click Create > Decision > Declare Expression.
- In the Target Property field, enter or select .LoanRate.
- Click Create and open.
- In the Build Expressions area, in the Value of drop-down, select Result of Decision Table.
- In the empty field to the right, enter or select BorrowerRiskAdjustmentTable.
- Click Save.
Confirm your work
- In the header of Dev Studio, click Create > New > Loan Request to create a new Loan Request case instance.
- In the Loan amount field, enter 10000.
- In the Credit score field, enter 750.
- Click Submit.
- Verify that the Loan rate is 2.75%.
- Optional: Create additional case instances and enter different Credit score and Loan amount values. Verify that the Loan rate is consistent with the values specified in the Borrower risk adjustment decision table.