You can import a rule association table into a model using SAS Profitability Management automation. You can either
To import a rule association table into an existing model, you proceed as though you were importing a model with the difference that:
- you specify Action="AddOnly" in your XML configuration file.
The AddOnly attribute specifies that the existing model is retained, and associations in the rule association table that don't already exist in the model are added to the model.- in your model import file, you include tags to identify the rule association table(s) to be imported.
The following is a sample model import file that can be used to import a rule association table:
<?xml version="1.0" encoding="utf-8"?> <Model Name="BabyBank" Action="AddOnly"> <BehaviorAssignmentTables> <Table Libref="BBankIn" Name="Association"> <ColumnMapping Required="behaviorReference" Actual="behaviorId"/> <ColumnMapping Required="tableGroup" Actual="tableGroup"/> <ColumnMapping Required="rule" Actual="rule"/> </Table> </BehaviorAssignmentTables> </Model>Notes:
- The model import file specifies only the elements being added to the model—in this case, rule associations. It does not specify elements already in the model, such as its behavior table.
- The model import file can also specify one or more assignment rules tables to be imported into the model.
- The model import file specifies the actual name of each of the following required columns in the rule association table:
Type this: Specify this: Required="behaviorReference" Actual="your-column-name" Required="tableGroup" Actual="your-column-name" Required="rule" Actual="your-column-name"
When you import a model, you can specify one or more rule association tables to be imported along with the model. You can import a rule association table instead of, or in addition to, specifying the individual associations in the model import file. The following shows an example of a model import file that references a rule association table to be imported with the model:
By contrast, the following shows a model import file in which the rule associations are explictly defined inline in the file:
Note: you can both import a rule association table and define associations inline, as the following XML file fragment illustrates:
To import a rule association table, in addition to creating the XML configuration file, you must also