When you set bindings for a data rule, you connect each
local variable used in the rule logic to an implemented data resource,
global variable, or literal value.
About this task
When you set the bindings for a data rule, you
create a direct relationship between a logical element in your rule
definition, such as "fname", and an actual column in one of your data
source tables, such as the "first_name" column in your employee first
name table. Instead of referring to a conceptual first name, for example,
you are defining what table you want the first name data to come out
of, and you are binding that element so that whenever you run the
data rule that you create, the data rule always extracts the first
name from the specific table that you created a binding for.
To
set the bindings for a data rule, you must first open an existing
data rule, or create a new data rule. You can create a new data rule
by either highlighting an existing rule definition and clicking Generate
a Data Rule, or by running a test on an existing rule
definition, going to view output, and then clicking Save
as a Data Rule. If you generate a data rule from the
test results, then the bindings that you specified for the test are
saved. If you generated a data rule from a rule definition, then
you must bind physical data sources to the data rule by using the
following steps. If you want to modify the bindings that you set
when you generated a data rule from the test results page, you can
use the following steps below after you open the data rule so that
you can edit it.
Procedure
- From the Data Quality workspace,
open the data rule that you want to set the bindings for or click Generate
a Data Rule or Rule Set. If you click Generate
a Data Rule or Rule Set, then specify a name for the data
rule.
- From the Overview and Binding
and Output tabs at the top of the screen, click the Bindings
and Output tab.
- Click Bindings in the Select
View menu on the left side of the screen. Each logical
variable that is a part of your data rule is displayed with the following
elements:
- Name
- The name of the logical variable that is part of your data rule.
- Rule Definition
- The name of the rule definition that you are working with.
- Data Type
- The data type of the logical variable.
- Design Binding
- The implemented data resource, global variable, or literal that
the local variable is bound to. The design binding is the default
binding of the rule variable. The design binding name is determined
by the object you add from the tabbed palettes to the source or reference
data cells when creating the rule logic. If you hand-type the variable
Col into the cell, there would be no design binding. Hand-typed rule
variables will not have design bindings.
- The design binding name is determined by the object you add from
the tabbed palettes to the source or reference data cells when creating
the rule logic. If you hand-type the variable Col into the cell, there
would be no design binding. Hand-typed rule variables will not have
design bindings
- Implemented Binding
- The column that is bound. You select an implemented binding from
the list based on the design binding.
- In the Rule Elements box, click the Binding box
for the data rule element that you are working with. With the box
you are working with still highlighted, move your cursor over to the
Tabbed Palette in the right side of the screen. Select one of the
following tabs: Implemented Data Resources, Global
Logical Variables, or Literal.
- Click Discover Bindings to identify
potential matches based on the Physical Model definition.
- After you select a tab that contains the data you want
to work with, click the data that you want to bind to your data rule
element. Then click Set as Binding. You can
also double-click the data source that you want to bind your data
rule element to, and automatically set your bindings.
- When you finish setting the bindings, click Save or Save
and Close in the lower right corner of the screen.
Example
For example, you have a rule definition for social security
number validation named Validate_SSN. You want to bind the column Col to
the Physical Column SSN. This is what you would have
in the rule definition:
Table 1. Defining the Implemented
Binding for this exampleName |
Rule Logic |
Data Type |
Design Binding |
Implemented Binding |
Validate_SSN |
SSN matches_format '999-99-9999' |
String |
SSN |
From the Implemented Binding list, you find
that the Physical Column has been implemented by a set of implemented
data resources:- Table1.SSN
- Table2.SocialSecurityNumber
- Table3.SSS_Code
For this example, you select Table2.SocialSecurityNumber
to validate social security numbers.
|
In this example, the Design Binding is SSN.
The Implemented Bindings include a list of
all those implementation models that implement the Design
Binding SSN, which are Table1.SSN, Table2.SocialSecurityNumber,
and Table3.SSS_CODE.
What to do next
Now you can add information to the
Join Keys or
the
Output screens that you can access from
the
Select View menu on the left side of the
screen.