Outcome format with the Outcome data source connector

When the Outcome data source connector is used for Outcome data, the system writes the data in the XML format used by previous versions of Opportunity Detect.

Fields in the Outcome table

The following table describes the fields in the Outcome table when you use the Outcome data source connector.

Table 1. Fields in the Outcome table
Field Description
AUDIENCEID ID of the audience for which the trigger system fired. Examples of an audience are account, customer, or household.
RUNID ID of the run. The Run ID helps distinguish between the Outcomes of one run versus the Outcomes of runs before or after it. Because of the Run ID, you do not need to truncate the Outcome table after every run because you can query the table for all of the Outcomes in a specific run.
COMPONENTID Unique ID of the Action component that fired to generate the Outcome.
AUDIENCETYPE The single character audience code assigned on the Opportunity Detect Audience Levels page.
OUTCOMEDATE The timestamp of the final event that caused the Action to fire.
MESSAGE The data that was specified in the Message and Additional Information fields of the Action component. The data is written in XML format.
ROW_NUMBER A unique sequence field, generated automatically.

XML format of the message field of the Outcome table

The XML in the message field of the Outcome table contains the data specified in the Message and Additional Information fields of the Action component.

Here is an example of the XML for a simple Outcome. The Action component in the example includes the following information in the Outcome.

  • Message field: Send printer paper offer.
  • Additional Information field:
    • The sum of all values in the field named Amount in a Container component named All Transactions.
    • The field named zipcode in the data source named Customer Profile.

			<OUTPUT>
				<TEXT>
					Send printer paper offer.
				</TEXT>
				<CONTAINER name"All Transactions" field="Amount" function="SUM">
					123.45
				</CONTAINER>
				<DATASOURCE name="Customer Profile" field="zipcode">
					11746
				</DATASOURCE>
			</OUTPUT>		
			

XML format of Outcome values from Container and Select components

Select and Container components can hold values that consist of a single value or a set of fields.

If the value has been aggregated into a single number using a function, it is called a scalar value. Here is an example of the XML for a scalar value where the Outcome includes a field named Amount from a Container component named C1. The Amount field is aggregated using the average function.


			<CONTAINER name="C1" field="Amount" function="average">
				123.45
			</CONTAINER>
		

If the value is a set of fields, it is called a tabular value. Here is an example of the XML for a tabular value where the Outcome includes fields named Field_1, Field_2, and Field_3 from a Select component named S1.


			<SELECT name="S1">
				<ROW>
					<FIELD name="Field_1">abc</FIELD >
					<FIELD name="Field_2">123.45</FIELD >
					<FIELD name="Field_3">xyz</FIELD >
				</ROW >
			</SELECT >