Scheduling a flat file import for IBM Product Recommendations

If you receive flat file recommendations from IBM Product Recommendations, formerly known as Coremetrics Intelligent Offer, you can import the recommendations into WebSphere Commerce database according to a schedule. The ImportIntelligentOfferAssociations scheduled job creates merchandising associations by using the flat file recommendations. Use the Administration Console to schedule the ImportIntelligentOfferAssociations job to run on your store.

Procedure

  1. Open the Administration Console and select Store on the Administration Console Site/Store Selection page.
  2. Select the store in which you want to create the merchandising associations. For an extended site, the merchandising associations can be created in an extended site store. Alternatively, select a catalog asset store if the merchandising associations should be shared with all the extended site stores that refer to the catalog asset store.
  3. Click Configuration > Scheduler. A list of jobs that are scheduled to run is displayed.
  4. Click New. The New Scheduled Job page opens.
  5. From the Job command list, select ImportIntelligentOfferAssociations.
  6. Enter the appropriate mandatory and optional parameters in the Job parameters field.
    The following table contains some examples of entries; the full set of mandatory and optional parameters are described after the table:
    Your goal Example of Job parameters field entry
    To import recommendations from all the flat files in a directory directory=C:\IntelligentOffer
    To import recommendations from an individual flat file directory=C:\IntelligentOffer&file=IO_912345_ProductPageOffer_20100427_I.txt
    To import recommendations from all the flat files in a directory into a workspace directory=C:\IntelligentOffer&workspaceIdentifier=W_10001&taskGroupIdentifier=G_10001&taskIdentifier=T_10001
    directory
    (Mandatory) Specify the directory in which the flat files are located. If the file parameter (see below) is not specified, then the recommendations are imported from all the files in this directory that match the pattern IO_****_I.txt. If the file parameter is specified, then the file must be located in this directory. Any error logs generated during the import are created in this directory.
    file
    Optional: Specify an individual flat file from which to import the recommendations.
    offerName
    Optional: If you do not want the command to determine the offer name from the flat file name, then you can specify the offer name with this parameter. This is required only if the offer name entered in the IBM Product Recommendations tool contains underscores. In most situations, this parameter is not required. The value of this parameter should match the offer name that is contained within the flat file that IBM Product Recommendations provides. Use the offerName parameter only when you include the file parameter.

    The following optional parameters are used to import the recommendations into a workspace:

    workspaceIdentifier
    The system-generated identifier for the workspace, not the name that is assigned to the workspace by the Workspace Manager.
    taskGroupIdentifier
    The system-generated identifier for the task group, not the name that is assigned to the task group by the Workspace Manager. Specify either this parameter or the taskGroupName parameter.
    taskGroupName
    The name that is assigned to the task group by the Workspace Manager. Specify either this parameter or the taskGroupIdentifier parameter. If you specify this parameter, ensure that there is only one working task group with the specified task group name, since multiple task groups can have the same task group name. Otherwise, the data load utility throws an exception.
    taskIdentifier
    The system-generated identifier for the task, not the name that is assigned to the task by the Workspace Manager. Specify either this parameter or the taskName parameter.
    taskName
    The name that is assigned to the task by the Workspace Manager. Specify either this parameter or the taskIdentifier parameter. If you specify this attribute, since multiple tasks can have the same task name, ensure that there is only one working task with the specified task name. Otherwise, the Data Load utility throws an exception.
  7. Set the Schedule interval field to reflect your preferred interval. This value is the number of seconds between when the job is restarted. If you receive flat files daily from IBM Product Recommendations, set this value to 86400 (86400 seconds equals 24 hours).
  8. Complete the remaining fields and click OK.

    Your job is listed on the Scheduler Status Display page and runs at the specified start time.

Results

If the import completes successfully, then the status of the scheduled job on the Scheduler Status Display page is Successful. If the import fails, then the status is Failed. If there are errors during the data load portion of the import, then an error log file is created in the directory that is specified in the directory parameter. Other errors during the import are logged in the SystemOut.log error log file.

You can view the import status in the Management Center Catalogs tool. See Viewing the import status of flat file recommendations for IBM Product Recommendations

What to do next

To test flat file recommendations, marketing managers can create web activities by using the Display IBM Product Recommendations action:
For the web activity, you can use any e-Marketing Spot that uses one of the following e-Marketing Spot snippets:
  • ContentAreaESpot.jsp
  • ESpotNavDisplay.jsp
  • ScrollingProductESpot.jsp