Eight Steps to Crafting a Business Rule — Step 4: Start with the Subject
Last month, I described the third step in an eight-step approach for crafting a business rule. The steps we have covered are:
- Extract the business rule.
- Determine whether the business rule already exists.
- Determine whether the business rule computes or derives something.
So far, we've done a lot of work — but we haven't actually started writing any business rules! This step is where we finally put pen to paper ... or should that be "fingers to keyboard"?
A business rule always constrains things in one way or another. So if you can figure out what is being constrained and start the rule statement with that, the rest of the rule will follow. In fact, the rule practically writes itself!
Now, this isn't always as easy as it sounds. Here are some things to watch out for:
1. Vocabulary
Your source material doesn't necessarily use the appropriate terminology, so sometimes finding the right subject requires "translating" from the source material to the correct term. If you did the mapping from the terms in the source material to the concept model as suggested in the previous steps, you will save time here.
2. "You" as a subject
Certain kinds of source material tend to be written in a friendly voice, using "you" as the start of a sentence. Example: "You can apply in person only during business hours." Determine what role (i.e., 'applicant', 'customer', 'claimant', etc.) the person in question is playing and use that role in the rule. In the example, the role appears to be 'applicant' so you should probably start with that.
3. A role as a subject
Even though it is perfectly acceptable to use a role of a person as a subject (e.g., 'customer', 'customer service representative', etc.), you should always question whether the rule applies to any other role(s). If the rules you are writing are process rules[1] then it is likely that the rule is specific to a given role or actor in the process (e.g., approvals must be done by a specific actor such as a manager).
However, if you are writing rules that describe a product or service, the subject is usually about that product or service in some way. Example: "An accountholder must not withdraw more money than is in their account." In actual fact, money should never be withdrawn by anyone — not just accountholders — if there isn't enough money in the account. What's really being constrained is a 'withdrawal', so that is the best subject to use.
4. The company as a subject
Some source material refers to the company itself (e.g., "The company will….", "Acme Widgets will…."). When writing business rules, the context is usually your company. So normally you do not need to reference the company in the rule. Look at the rest of the sentence for clues to what the subject might be.
5. Hidden subjects
Sometimes the subject is hidden altogether and you need to ferret it out. Try to think of what is being constrained. For example, a sign in a restaurant might say "No less than two people in booths between 9 am and 1 pm."[2] So what is being constrained — is it the people? Is it the booth? Given that this rule is written from the perspective of a restaurant that wants to maximize its revenue, I would say it is probably booths that are being constrained.
6. Interchangeable subjects and objects
Sometimes when you write a rule, you'll find that it can be written in two ways simply by reversing the subject and object of the sentence. For example, "A high risk customer must not place a rush order." can just as easily be written as "A rush order must not be placed by a high risk customer." As the two statements are logically equivalent, it doesn't really matter which you choose.
I tend to look at the context of the rule and start with that. If I know what task the rule is guiding, I will start the rule from the perspective of the actor in the task. So if the task is "Place Order" with the customer as the actor, then I will start the rule with 'high risk customer'. However, if the task is 'Approve Order' and the actor is a manager, I will start with 'order' as the subject because the manager is probably applying several rules about orders to determine whether or not the order can be approved. In cases where the rule is applied in more than one task, pick the form that is most natural to the business and that communicates to the audience best.
Once you have settled on your subject, here are some additional conventions to follow:
- Always show the subject in the singular form — rules always apply at the instance level.
- Start with "A" if there is more than one instance of the subject; but use "The" if there is only one. For example, a rule statement might start with "A vehicle…." or "The birth date of a person…." Some business analysts that I've mentored find this convention somewhat esoteric and roll their eyes when I comment on it. But I find it to be a simple guideline to follow — one that always adds greater consistency and clarity to the rules. In any case, it's simply good grammar.
- Start with "Each" or "Every" if it makes the rule read better. Some authors[3] advocate always using one of these words at the beginning of a rule (assuming the subject has multiple instances). Although this convention does add a degree of precision, I find that business people don't always respond well to it — it feels too technical or stuffy. However, there are times when it does make sense to use it.
So, with your subject chosen, you're off to a good start. Next month, I'll talk about choosing the right business rule keyword (i.e., "must" or "only").
Notes:
[1] Process rules ensure that a process functions as effectively and efficiently as possible.
[2] Source: Tilly's Restaurant in Alameda, CA.
[3] For a convincing case for using 'each', see Graham Witt's series on natural language rules, which is running concurrently with this series.
General References:
Building Business Solutions: Business Analysis with Business Rules, by Ronald G. Ross with Gladys S.W. Lam, An IIBA® Sponsored Handbook, Business Rule Solutions, LLC, October 2011, 304 pp. URL: http://www.brsolutions.com/bbs
For more information on the RuleSpeak® technique, visit http://www.rulespeak.com
# # #
About our Contributor:
Online Interactive Training Series
In response to a great many requests, Business Rule Solutions now offers at-a-distance learning options. No travel, no backlogs, no hassles. Same great instructors, but with schedules, content and pricing designed to meet the special needs of busy professionals.