Calculate a Model (via Automation)

To calculate a model with SAS Profitability Management automation, you must create an XML configuration file to control the task. The following is a sample XML configuration file:

 
<Operation Model="BabyBank">
   <Task Type="Calculate" NumberOfSessions="1">
       <ExceptionReport>
          Libref="bbankout"
          TransactionSuffix="_UT"
          BehaviorSuffix="_UB">
       </ExceptionReport>
       <TransactionTableGroups>
          <TransactionTableGroup Name="ABMCost"/>
          <TransactionTableGroup Name="CallCenter"/>
          <TransactionTableGroup Name="Revenue"/>
       </TransactionTableGroups>
       <Periods>
          <Period Name="2008_Q4_Actual"/>
          <Period Name="2008_Q4_Budget"/>
       </Periods>
       <SummaryReports>
          <Report Name="Eastern"/>
          <Report Name="Western"/>
       </SummaryReports>
   </Task>
</Operation>

The xml configuration file contains the following attributes that you must specify.

Attribute Value
Model= specifies the name of the model to be calculated.
Task Type=

Calculate

NumberOfSessions=

specifies the number of multiple concurrent sessions for calculation.

RowCount=

specifies the maximum number of transaction table rows to process for the calculation.

If you do not specify RowCount=, then all rows are processed. Specifying RowCount= validates the model without spending the time to completely calculate the model.

ExceptionReport
  Libref=
specifies the libref of the SAS library to receive exception report tables.
TransactionSuffix=

specifies the suffix of the transaction tables exception report.

If you do not specify TransactionSuffix=, then the transaction tables exception report is not generated.

BehaviorSuffix=

specifies the suffix of the behavior table exception report.

If you do not specify BehaviorSuffix=, then the behavior table exception report is not generated.

TransactionTableGroup
  Name=

 

IncludeAll="true"

specifies the name of each transaction table group to be calculated.

Note: If you want to calculate all the model's transaction table groups, you do not have to list them all. Instead, you can specify IncludeAll="true" in the following format:

 
<TransactionTableGroups IncludeAll="true"/>

Period
  Name=

 

IncludeAll="true"

specifies the periods to be calculated for each of the transaction table groups that is calculated.

Note: If you want to calculate all periods, you do not have to list them all. Instead, you can specify IncludeAll="true" in the following format:

 
<Periods IncludeAll="true"/>
    

Report
  Name=

 

IncludeAll="true"

specifies the summary reports (cubes) to be generated for the model.

Note: If you want to generate a cube for every summary report, you do not have to list them all. Instead, you can specify IncludeAll="true" in the following format:

 
<SummaryReports IncludeAll="true"/>
    

To calculate a model, in addition to creating the XML configuration file, you must also

Note: You can construct your XML configuration file to perform multiple tasks with a single job. For example, the following configuration file imports a model and then calculates it:

 
<Operation Model="BabyBank New">
   <!-- Import BabyBank as BabyBank New -->
   <Task Type="Import" Action="Replace">
      <Source Type="XML" FilePath="BabyBank.xml"/>
   </Task>
   <!-- Calculate BabyBank New -->
   <Task Type="Calculate" NumberOfSessions="1" RowCount="5">
       <ExceptionReport>
          Libref="bbankout"
          TransactionSuffix="_UT"
          BehaviorSuffix="_UB">
       </ExceptionReport>
       <TransactionTableGroups>
          <TransactionTableGroup Name="ABMCost"/>
          <TransactionTableGroup Name="CallCenter"/>
          <TransactionTableGroup Name="Revenue"/>
       </TransactionTableGroups>
       <Periods>
          <Period Name="2008_Q4_Actual"/>
          <Period Name="2008_Q4_Budget"/>
       </Periods>
       <SummaryReports>
          <Report Name="Eastern"/>
          <Report Name="Western"/>
       </SummaryReports>
   </Task>
</Operation>

See also: