
- Subscribe to RSS Feed
- Mark as New
- Mark as Read
- Bookmark
- Subscribe
- Printer Friendly Page
- Report Inappropriate Content
Have you ever created a three tiered dependent list? Have you ever tried it when some of the options on the second tier are the same?
You're probably aware of the dependent choice lists Category and Subcategory from the OOB incident examples. If you choose Category=Software, you get a certain list of choices in the Subcategory field to choose from. If you choose Category=Hardware, the Subcategory field values change accordingly. Note that in the sample data, all the Subcategory values are different. This will come up later.
Let's back up a second… For each option in the choice list, there is the text, Hardware for example, and the value. Values can be the same as the text or different. Let's say the "Hardware option can have the value "Hardware", "hw", or even "200". While the text may change based on the language selected, the value is always constant for that option. It is used in scripts and dependent lists to determine which choice was actually selected.
I ran in to an interesting situation last week when we were creating a three level dependent list that had the same values in the second level dependent choice list. Let's use the example of a Change Request where we want a State, Substate, Detail. Our goal is to create a structure similar to the following where State is the first row, Substate is the second, and Detail is the third:
At first glance, this doesn't look to bad. It's a simple matter of creating new fields and choices - until you see all those Pending substates. If you try the straight forward approach (as I first did) and create a Substate option of Pending for State Assess, then create the two Detail values that depend on Pending, you'll see the issue when you use Pending again (in State Plan). You want to add Planning Review and Business Owner Approval, but Pending already has two dependent values "Technical Review" and "Functional Review".
Here's where values come in. Use unique values for each choice list option, even if it's the same text, it has a unique value. For the states:
- Draft=100
- Assess=200
- Plan=300
- Implement=400
- Closed=500
By default, when you create choice list options (right click on a choice field and Personalize Choices) it uses the name of the choice as the text and the value. If you right click and say "Show Choice List", you'll see all the options and their corresponding values. using the list editor, you can change the values to what you want. I also recommend personalizing the list to see the dependent values.
Next, create substates in increments of 10 from the state. For example:
- State: Assess (200), Pending=210
- State: Plan (300), Pending=310
- State: Implement (400), Pending=410
- State: Implement (400), Work In Progress=420
Now when you create the Detail options, they are dependent on unique values. For State=Assess, Substate=Pending, Details "Technical Review" and "Functional Review" are dependent on 210, not "Pending". Hence, there's no conflict when you get to Plan because "Planning Review", and "Business owner approval" are dependent on 310.
If you choose, you can make the Detail options have values as well (e.g. 211, 212 for Technical Review and Functional Review), that's up to you. If nothing depends on it and you don't mind quoting the values in scripts, there's little value save consistency with the rest of your hierarchy.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.