Identifying business rules
Business rules constitute actions to be taken when certain conditions are true. You can use Z Understand to identify business rules in your application and describe them by using natural language. You identify business rules by looking at how variables are used in the code of a program and tracing back through the code to find out how that variable is used.
About this task
Use the watsonx chat to help you identify where you want to start identifying business rules in your application. Try to be specific and work in just a few programs at a time.
Procedure
- Find the relevant variables for the business rules of your application.
Always start with the chat. When you start a new conversation, you get a quick action to identify business rules. This takes you to the right tab in the UI and prompts you to ask about the business function that you are interested in. This is the first step in identifying business rules.
If business rules already apply to your application, they are listed in the Business rules panel of the Dashboard, the entry point into the Web UI. You can click them to see their details.
To identify new business rules, find the variables that they will be created from. To do so, complete the following tasks:
- Click Identify business rules in the Business rules panel of the Dashboard or click the Business rules button in the navigation panel. You automatically switch to the Identify business rules tab of the Business rules.
- To reduce the number of variables, you can focus on a few programs that contain a specific
business function.
Enter their names in the Search for programs field. As auto completion is active, you can enter a partial program name. Select the programs, one at a time.
- Work with the variables table.
The AI semantic search parses the specified programs to find all the variables that they use.
All the variables that are found by the AI are displayed in a table in the Identify business rules tab. If you entered multiple programs for the search, the table contains a section for each program.
In the table, the variables are ranked according to how likely they are to be used in business rules. So, the most relevant variables are displayed first.
The descriptions and associated business terms start with the AI tag if they were generated by the AI. You can click a description, click the Edit button that becomes available on the row, and overwrite the generated description. The AI tag disappears. You can click the Revert to AI input to cancel your input.
The table displays the following details for each variable:- The variable name found in the code of the application.
- An AI-generated description, with an AI tag.
- An AI-generated business term, with an AI tag.
- The source program where the variable was found.
- The related variables, which give more context for the variable.
- The aliases, if any, which apply to the variable in the source program. An alias is the same variable but used under another name in the code.
You can complete the following actions on the variables:- Click any generated description or business term. You can then approve the AI input or edit it by using the buttons that become available in the table cells. The AI tag is automatically removed if you approve or edit the AI input. You can revert to the AI-generated input by clicking Revert to AI input that becomes available when you click the changed value.
- Open the expandable section of each variable to see the following details on the variable:
- An AI-generated business description.
- The source program where the variable was found.
- The related variables, which give more context for the variable.
- The aliases, if any, which apply to the variable in the source program. An alias is the same variable but used under another name in the code.
- Click the Hide variable button at the end of a table line to remove the
variable from the table. You can do so if the variable is an error variable or if the variable is
not relevant.
If you click Remove in the confirmation dialog, the variable is excluded from the list of the variables that are used to create the business rule.
You can unhide the variable by clicking Unhide all in the table header.
- Create business rules from the variables in the table.
- Click a variable name or source program in the same row to start the two-step variable usage and identify business rule process.
- The Select variable usage tab automatically opens. It displays the source
program code. The list of the variable usages is displayed and sorted by the starting line number.
Select one of the usages to highlight it in the code.
- Click Next.
- The Review generated rule tab that opens displays the Business
rule summary and Details sections.
- After you reviewed the proposed business rule, click Create to create it.
- Click the Business rules tab to see that the new business rule is
listed among the business rules of the application.
If you click this business rule, you can see its details.