38 Creating Visitor Data Assets

Engage lets you design online sites that gather information about your site visitors and customers, and then to use that information to personalize the product placements and promotional offerings that are displayed for each visitor.

Customizing your online sites begins with visitor data. The definitions of visitor data types are treated as assets in the WebCenter Sites database. There are three kinds of visitor data assets: visitor attributes, history attributes, and history types.

This chapter describes the visitor data assets and presents procedures for creating them. It contains the following sections:

38.1 About Visitor Data Assets

You create visitor data assets so that you can use them to group your site visitors into segments. There are three kinds:

  • Visitor attributes

  • History attributes

  • History types

When you create visitor data assets, you create entries in the visitor data tables in the WebCenter Sites database and you reserve a place in the database to store information of that kind for your site visitors.

This section contains the following topics:

38.1.1 Visitor Attributes

Visitor attributes hold types of information that specify one characteristic only (scalar values). For example, you can create visitor attributes named "years of experience," "job description," or "number of children."

When the visitor changes the data, the new data overwrites the old data. Engage does not assign a timestamp to the data that is stored as a visitor attribute and does not store revisions. For example, if a visitor changes his entry for "job description" from "butcher" to "baker," the information that the visitor was once a butcher is overwritten. You cannot, for example, create a segment based on bakers who used to be butchers.

For historical data, you must use history types.

38.1.2 History Attributes and History Definitions

History attributes are individual information types that you group together to create a vector of information that Engage treats as a single record. This record is the history definition. For example, a history definition called "purchases" can consist of the history attributes "SKU," "itemname," "quantity," and "price."

Engage references data stored as a history definition as a whole or an aggregate. It assigns a timestamp to each instance of the recorded definition and keeps each of those records. This means that you can sum or count history definitions and you can determine the first time or the last time a history definition was recorded for a visitor. Using the example in the preceding paragraph, you can create a segment based on the amount of money a visitor spends on specific items during a set period of time.

History definitions store historical data.

38.1.3 Segments

Segments are assets that divide visitors into groups based on common characteristics. Segments are built by determining which visitor data assets to base them on and then setting qualifying values for those criteria.

When you create visitor data assets, you create fields. These fields can be used in two places:

  • As criteria for segments. That is, as configuration options in the Engage Segment Filtering forms (because you define segments with the visitor data assets). In other words, the choices you make about the data types for the attributes determine their appearance and behavior in the Segment forms. When you create these assets, you are customizing the Segment forms.

  • On your public site pages. That is, as form fields or hidden fields on registration pages and other pages.

Segments are the key to personalizing merchandising messages with Engage. When visitors browse your site, the information they submit is used to qualify them for segment membership. When the site displays a page with a recommendation or promotion, Engage determines which segments a visitor belongs to and displays the product recommendations or promotional messages that are designated for those segments.

38.1.4 Developing Visitor Data Assets: Process Overview

There are five general steps for creating and using visitor data assets (fields):

  1. A cross-functional design team including developers and marketers determines what kind of data you want to gather about your site visitors.

  2. You (the developers) create and define the necessary visitor attributes, history attributes, and history definitions by using the forms in Engage.

  3. The marketers use the Segment Filtering forms in Engage to categorize groups of visitors based on these visitor attributes, history attributes, and history definitions.

  4. You program the appropriate site pages with the Engage XML or JSP object methods to collect and store the data, using either server-side validation or Javascript to validate the input on the pages. For example, you can create an online registration form for visitors to fill out by using JavaScript to validate the input and the Engage XML or JSP tags to process and store that information in the WebCenter Sites database.

  5. When visitors browse your site, the information they submit is used to qualify them for segment membership. If your site is using promotions and recommendations based on segments, the message displayed for the visitor is personalized based on the segments that he or she qualifies for.

38.2 Creating Visitor Data Assets

Before you begin creating visitor data assets, be sure that you have completed the following tasks:

  • Met with the marketing and design teams to determine the kinds of data that you want to collect about visitors.

  • Examined the Segment Filtering forms so that you understand the context in which the visitor data assets that you create are used by the marketers. Additionally, note that the visitor data assets are listed by their descriptions rather than by their names in the Segment Filtering forms.

You can use the following data definitions for your visitor and history attributes:

  • string: can hold up to 255 characters

  • boolean: true and false are the only legal values

  • short: valid range of values is 0 through 255

  • integer: valid range of values is 0 through 65,535

  • long: valid range of values is 0 through 65,535

  • double: valid range of values is 0 through 4,294,967,295

  • date: format is yyyy-mm-dd hh:mm:ss.s

  • money: format is currency; valid range of values is unlimited

  • binary: for visitor attributes only; used for binary data such as image files or cart objects

    Note:

    Binary visitor attributes can record binary data for individual visitors. Visitor attributes of this type are not displayed in the Segment Filtering forms and cannot be used to define a segment. Creating an attribute of type binary reserves space in the WebCenter Sites database that you use to store objects by using the XML object method VDM.SAVESCALAROBJECT or its JSP equivalent vdm:savescalarobject to convert an object from the WebCenter Sites name space into a binary form.

This section contains the following topics:

38.2.1 Creating Visitor Attributes

Use the procedures in this section to create visitor attributes with the Engage forms.

To create a new visitor attribute, complete the following steps:

  1. Log in to WebCenter Sites as an administrator.

  2. Select the site in which you want to work.

  3. Select the Admin interface.

  4. Click New on the button bar.

  5. Select New Visitor Attribute from the list of asset types. (Site Visitor Attribute asset types must be enabled for your site.)

    The Site Visitor Attribute form displays.

    Figure 38-1 Site Visitor Attribute

    Description of Figure 38-1 follows
    Description of "Figure 38-1 Site Visitor Attribute"

Note:

If Visitor Attribute does not appear in the menu list, it means that your login password combination does not give you administrator rights. Contact the site administrator and request that the admin user profile be assigned to your user name.

  1. In the Name field, enter a unique, descriptive name for the attribute (field). You can enter up to 32 alphanumeric characters, including spaces. The first character must be a letter.

  2. In the Description field, enter a description of the attribute (field). Enter a value (alphanumeric characters) that will help you easily identify the attribute (attributes are listed by their descriptions rather than their names in the Segment Filtering forms).

  3. In the Category field enter the category for the attribute. The text that you enter in this field determines where the attribute is listed in the Segment Filtering form. You can enter up to 32 alphanumeric characters.

    Note:

    Categories for visitor attributes must be different from the categories for history definitions.

38.2.1.1 Configure the Data Type

  1. In the Type field select a data type.

  2. If you selected string, in the Length field enter the maximum number of characters allowed for input in the attribute (field). You can enter a value up to 255.

  3. In the Null allowed field, select true to allow null values or false to require input for the attribute when it is used. For example, an attribute with a Boolean data type cannot allow a null value.

  4. If you selected false in the Null allowed field, in the Default Value field enter a default value that is appropriate for the attribute's data type. For example, if the data type is "integer" the default value must be a number.

Note:

If you selected binary as the data type, you cannot specify a default value for the attribute.

38.2.1.2 Configure the Constraint Criteria

The constraint options that are available for validating input into the attribute depend on the data type that you designated for the attribute.

Option 1: Configure the attribute to accept free-form text

In the Constraint type field select none from the drop-down list. For example, a visitor attribute named residence of type string might accept unconstrained text as input.

Option 2: Configure the attribute to accept input from a range of values

To configure the attribute to accept a specific range of values, the data type must be integer, short, long, double, or money.

  1. In the Constraint type field select range.

    The form displays range fields.

  2. In the Lower range limit field and specify the smallest possible value that can be accepted in the attribute when it is used as a field. This value cannot be a negative number.

  3. In the Upper range limit field, enter the largest possible value that can be accepted in the attribute when it is used as a field. (For a short data type, you can enter a value up to 255; for integer, up to 65,535; for double, up to 4,294,967,295; for money, unlimited.)

    For example, an attribute named Age can be restricted to accept only values between 1 and 110.

    Figure 38-2 Range Fields for the Constraint Type

    Description of Figure 38-2 follows
    Description of "Figure 38-2 Range Fields for the Constraint Type"

Option 3: Configure the attribute to offer a set list of values in a drop-down list

  1. In the Constraint type field and select enumeration.

    The form displays text boxes for adding options.

  2. In the Add Enumerated Value field, enter the name of the first option. For example, an attribute named "gender" can have "female" as an option.

  3. Click Add.

    The option is moved to the list.

    Figure 38-3 Enumeration Constraints

    Description of Figure 38-3 follows
    Description of "Figure 38-3 Enumeration Constraints"

  4. Repeat these steps for each of the options that you want to make available for this attribute (field).

38.2.1.3 Save the Attribute

  1. (Optional) If more than one site is set up and you have access to those sites, specify whether you want to share this attribute with the other sites. In the More menu on the Inspect form, select Share Visitor Attribute.

  2. When you are finished configuring the visitor attribute, click Save.

    Engage creates an entry for this attribute in the visitor data asset tables in the WebCenter Sites database and reserves a place in the database to store information of that type for your site visitors.

    Engage displays a summary of the attribute in the Inspect form.

You can now use this visitor attribute in a segment.

Note:

After a visitor attribute is used to define a segment, deleting the attribute invalidates the segment. Be sure to correct your segments if you delete an attribute.

38.2.2 Creating History Attributes

The purpose of history attributes is different from the purpose of visitor attributes: you create history attributes to be used by history definitions. You cannot use them in the Segment Filtering forms until they are used to define a history definition.

Use the procedures in this section to create history attributes by using the Engage forms.

Note:

You cannot edit or delete a history attribute after it has been used to define a history definition. You also cannot remove it from the history definition. If you must change a history attribute after it has been used to define a history definition, it is best to stop using the history definition. Create a new history attribute, create a new history definition, and then start using the new history definition.

To create a new history attribute, complete the following steps:

  1. Select the site in which you want to work.

  2. Select the Admin interface.

  3. Click New on the button bar and select New History Attribute from the list.

    The History Attribute form displays.

    Figure 38-4 History Attribute Form

    Description of Figure 38-4 follows
    Description of "Figure 38-4 History Attribute Form"

Note:

If History Attribute does not appear in the menu list, it means that your login/password combination does not give you administrator rights. Contact the site administrator and request that the admin user profile be assigned to your user name.

  1. Log in to WebCenter Sites as an administrator.

  2. In the Name field, enter a unique, descriptive name for the attribute (field). You can enter up to 32 alphanumeric characters, including spaces. The first character must be a letter.

  3. In the Description field, enter a description of the attribute (field). Enter a value (alphanumeric characters) that will help you easily identify the attribute (attributes are listed by their descriptions rather than their names in the Segment Filtering forms).

  4. In the Type field and select a data type.

  5. If you selected string, in the Length field enter the maximum number of characters allowed for input in the attribute (field).

  6. If you want this attribute to be a required field when the history definitions that use it are used to define a segment, select true in the Must be specified field.

  7. Click in the Filter by field and select true.

    If you do not set Filter by to true, the marketers cannot use the attribute (field) as a constraint for any history definition that it belongs to when they create segments.

    If the data type for this attribute is numeric, then by default the attribute is included in the list of attributes that can be selected for a Total constraint in a segment, whether you set Filter by to true or to false. However, if you want to use a numeric attribute as a constraint in any other way, you must set Filter by to true.

  8. Click in the Null allowed field and select true to allow null values or false to require input for the attribute when it is used. For example, an attribute with a Boolean data type cannot allow a null value.

  9. If you selected false in the Null allowed field, in the Default Value field enter a default value that is appropriate for the attribute's data type. For example, if the data type is integer, the default value must be a number.

38.2.2.1 Configure the Constraint Criteria

The constraint options available for validating input into the attribute depend on the data type you designated for the attribute.

Configure the attribute to accept free-form text

Click in the Constraint type field and select none from the drop-down list. For example, a history attribute named Street Name of type string might accept unconstrained text as input.

Configure the attribute to accept input from a range of values

To configure the attribute to accept a specific range of values, the data type must be integer, short, long, double, or money.

  1. In the Constraint type field, select range.

    The form displays range fields.

  2. In the Lower range limit field, specify the smallest possible value that can be accepted in the attribute when it is used as a field. This value cannot be a negative number.

  3. In the Upper range limit field, enter the largest possible value that can be accepted in the attribute when it is used as a field. (For a short data type, you can enter a value up to 255; for integer, up to 65,535; for double, up to 4,294,967,295; for money, unlimited.)

    For example, an attribute named "Number of Items" can be restricted to accept only values between 1 and 50.

    Figure 38-5 Range Constraints and Related Fields

    Description of Figure 38-5 follows
    Description of "Figure 38-5 Range Constraints and Related Fields"

Configure the attribute to offer a drop-down list of specific values

  1. In the Constraint type field, select enumeration.

    The form displays text boxes for adding options.

  2. In the Add Enumerated Value field, enter the name of the first option. .

  3. Click Add.

    Figure 38-6 Enumeration Constraints Fields

    Description of Figure 38-6 follows
    Description of "Figure 38-6 Enumeration Constraints Fields"

  4. Repeat these steps for each of the options that you want to make available for this attribute.

38.2.2.2 Save the History Attribute

When you are finished configuring the history attribute, click Save.

Engage creates an entry for this attribute in the visitor data asset tables in the WebCenter Sites database and reserves a place in the database to store information of that type for your site visitors.

You can now use this history attribute to define a history definition.

38.2.3 Creating History Definitions

History definitions are made up of history attributes. Therefore, there must be at least one history attribute created before you can create a history definition.

Use this procedure to create history definitions by using the Engage forms:

  1. If Engage is not open, log in.

  2. Click New and select History definition from the list.

    The History definition form appears:

    Figure 38-7 History Definitions Fields

    Description of Figure 38-7 follows
    Description of "Figure 38-7 History Definitions Fields"

    Note:

    If History definition does not appear in the menu list, it means that your login/password combination does not give you administrator rights. Contact the site administrator and request that the admin user profile be assigned to your user name.

  3. In the Name field, enter a unique, descriptive name for the history definition (record). You can enter up to 32 alphanumeric characters, including spaces. The first character must be a letter.

  4. In the Description field, enter a description of the history definition. Enter a value (alphanumeric characters) that will help you easily identify the history definition (history definitions are listed by their descriptions rather than their names in the Segment Filtering forms).

  5. In the Category field, enter a category for the history definition. The text that you enter in this field determines how the history definition is sorted and displayed in the Segment Filtering forms. You can enter up to 32 alphanumeric characters.

    Note:

    Categories for history definitions must be different from the categories for visitor attributes.

  6. In the Fields area, select the history attributes that make up this history definition. Select an attribute and then click the right arrow to move it to the list on the right. Use control + click to select more than one attribute at the same time.

    Note:

    After a history attribute is used to define a history definition, you can no longer edit or delete that history attribute.

  7. Click Save.

    Engage creates an entry for this history definition (record) in the visitor data asset tables in the WebCenter Sites database and reserves a place in the database to store information of that type for your site visitors.

    Engage then displays a summary of the history definition in the Inspect form.

You can now use this history definition in a segment.

38.3 Verifying Visitor Data Assets

To determine that the visitor attributes, history attributes, and history definitions are properly set up, examine the Segment Filtering forms and decide whether the visitor assets that you created were configured correctly:

  • Create segments that use each of the visitor attributes and history definitions that you created.

  • Determine that the constraint definitions are correct and that the input ranges are accepting the correct range of input.

38.4 Approving Visitor Data Assets

When your visitor data assets are ready, approve them so that they can be published to the delivery system.

When a history definition is published, the history attributes that are used to define it are also published. That means that you have to approve all the history attributes in a history definition before the history definition can be published.

To approve any asset, select Approve for Publish from the drop-down list in the icon bar in the asset's Edit or Inspect form.