How to Run a Scoring Model in Oracle

To run a scoring model using the SAS Embedded Process, follow these steps.
  1. Create a scoring model using SAS Enterprise Miner.
  2. Start SAS 9.3 and create a table to hold the scoring files.
    The %INDOR_CREATE_MODELTABLE macro creates a table that holds the scoring files for the model that is being published.
    For more information, see Creating a Model Table.
  3. Run the %INDOR_PUBLISH_MODEL macro to create the scoring files.
    The %INDOR_PUBLISH_MODEL macro uses some of the files that are created by the SAS Enterprise Miner Score Code Export node: the scoring model program (score.sas file), the properties file (score.xml file), and (if the training data includes SAS user-defined formats) a format catalog.
    The %INDOR_PUBLISH_MODEL macro performs the following tasks:
    • translates the scoring model into the sasscore_modelname.ds2 file that is used to run scoring inside the SAS Embedded Process
    • takes the format catalog, if available, and produces the sasscore_modelname_ufmt.xml file. This file contains user-defined formats for the scoring model that is being published.
    • uses the SAS/ACCESS Interface to Oracle to insert the sasscore_modelname.ds2 and sasscore_modelname_ufmt.xml scoring files into the model table that was created using the %INDOR_CREATE_MODELTABLE macro.
  4. Use the SASEPFUNC table function in the FROM clause in any SQL expression to run the scoring model.
    For more information see, SASEPFUNC Table Function.