Profile Definitions

You use the Profiles resource to create new profile definitions. A profile is a single instance of a profile definition, containing the data that the profile definition collects. For example, when a user enters data into a user profile definition on your Web site, Commerce Server 2000 creates a profile for the user that the business manager can access in Commerce Server Business Desk.

You can use the Profiles resource to add properties to a profile definition that specify what data the profile definition will collect, and to specify the attributes of the properties of a profile definition. Business managers can also do this using the Profile Designer module in Business Desk.

Associating Profiles

Mapping Profile Properties to Storage Locations

Profile Definition Components

Associating Profiles

You can use the Profiles resource to associate profiles. You associate profiles to expand the data that you collect with profile definitions. For example, you want to collect multiple addresses, such as a billing address and a shipping address, from users who purchase items on your Web site. You could do this by adding properties (such as First Name, Last Name, Street, City, State, and Zip Code) for each address you want to collect to the User Object profile definition.

A better way to collect multiple addresses is to add a single property to the User Object profile definition for each address, and use that property to associate address profiles with user profiles. For example, you add a property to the User Object profile definition called "Billing Address." You define the property type of Billing Address as profile. You then select the Address profile definition as the type reference for the Billing Address property.

When a user enters a billing address on your Web site, the billing address is stored in an address profile. The address profile is saved with a unique name. The unique name of the address profile is collected as a string in the Billing Address property of the user profile. Because the user profile contains the unique name of the address profile, the data in the user profile and the address profile can be presented together on your Web site and in reports. For instructions for associating profile definitions, see Adding a Profile Definition to a Profile Definition.

Mapping Profile Properties to Storage Locations

Profile properties use data members to map data entered by users on your Web site to the appropriate storage location. For example, when a user types a first name into the First Name property of the User Object profile definition, the name is stored in the database column that the data member for the First Name property specifies.

After a profile definition has been created with the Profiles resource, the business manager can modify the properties in the profile definition and manage the data available in individual user profiles in Business Desk.

Profile Definition Components

A profile definition contains properties, property groups, and attributes.

Properties

Properties define the actual data that is collected by a profile definition. For example, First Name is a property of the Address profile definition. You can define profile properties as the types in the following table.

Property type Description
String Stores up to a maximum of 4,000 Unicode characters. String properties map to string data members.
Long string Stores up to a maximum of 2 to the power of 17 (2^17) Unicode characters. Long string properties map to string data members.
Number Stores integers. The maximum length of a number property is determined by the data store. Number properties map to number data members.
Decimal Stores floating-point numbers. The maximum length of a decimal property is determined by the data store. Decimalproperties map to number data members.
Boolean Stores one of two values (for example, True/False, Yes/No, or 1/0). Boolean properties map to Boolean data members.
Binary Stores binary content, primarily for programmatic use, up to a maximum size of 4 kilobytes (KB). Binary properties map to binary data members.
Long binary Stores content, such as spreadsheets, documents, pictures, and audio clips up to a maximum size of 128 KB. Long binary properties map to binary data members.
Date/time Stores composite date and time values. The format and the maximum length are determined by the data store. Date/time properties map to date/time data members.
Date Contains date values. The format and the maximum length are determined by the data store. Date properties map to date/time data members.
Time Contains values for hour, minute, second, and millisecond. The format and the maximum length are determined by the data store. Time properties map to date/time data members.
Currency Stores numbers in currency format. The format and the maximum length are determined by the data store. Currency properties map to currency data members.
Password Stores text. The Profiles resource treats the password property like a string property. Business Desk displays the values stored in a password property as asterisks (*). Password properties map to string data members and have a maximum length of 255 Unicode characters.
Site term Stores valid values from the list of term names associated with the corresponding site term. Site term properties map to string data members and have a maximum length of 255 Unicode characters.
Profile Stores a value that corresponds to the value of the primary key of a specific instance of that associated profile. Profile properties map to string data members and have a maximum length of 255 Unicode characters.

The property type must be the same as the data type of the data member it is mapped with. For example, you map a string property with a string data member to a string column in the data store. Each property has attributes that define the characteristics of that property.

Property Groups

Property groups are logical groupings of profile properties. You use property groups to organize related properties into groups in the profile designer screen.

Attributes

Attributes are characteristics specified for a property or property group. For example, the property First Name has the profile property attributes Name, Display name, Description, and Type. There are two special types of attributes:

  • Advanced attributes. You use the advanced attributes described in the following table to change how your applications use a profile property. For example, the Exported attribute determines whether a property will be imported into the Commerce Server Data Warehouse.

    Attribute Description
    Active Indicates whether this property is displayed in Business Desk.
    Map to Data Identifies the data member this property uses to map to the database column (or LDAP attribute).
    Key Type Each profile definition requires a property that is a primary key and a property that is a join key, or a property that is a dual key (both primary and join keys). There are four key types you can assign:
    • Unique key. Indicates that the value of this property is unique for all members. Properties designated as unique keys have a U(key) symbol next to their names in the Properties list.

    • Primary key. Identifies the profile. The value of this property must be unique for each profile. You map a property that is specified as a primary key to a unique field in a database or LDAP source. Properties designated as primary keys have a P(key) symbol next to their names in the Properties list.

    • Join key. Relates the profile definition to multiple data objects. You use this to map the properties of the profile definition to data members from different data objects. If you are mapping the profile definition to multiple data objects, you must map the join key to a data member from each data object. This causes the data collected by the property (assigned as the join key) to be persisted in the storage locations represented by the data members. Properties designated as join keys have a J(key) symbol next to their names in the Properties list.

    • Dual (primary and join) key. Uniquely identifies the profile and maps the profile definition to multiple data objects. Properties designated as dual keys have a P(key)J(key) symbol next to their names in the Properties list.
    Required Specifies that this property is required on your Web site and in Business Desk. However, this attribute is not enforced by the Profiles resource. This attribute is read-only if you have selected a key type.
    Exported Specifies that this property is imported into the Data Warehouse. You can export only mapped properties. You cannot export properties that are multi-valued and of the type Boolean or properties of type binary, long string, and password.
    Defer Cache Indicates that this property will not be loaded initially when the profile is retrieved, but will be loaded when this particular property is accessed.
    Multi-valued Enables the collection of multiple values that are associated with this property. Not all data types and data stores support multiple values.
    Searchable Indicates that this property is indexed in the underlying data store and is available for searching through the Find By function. You map a searchable attribute to an indexed field in the database or LDAP source.
    RDN Identifies the Relative Distinguished Name (RDN) for a directory store. Set this value if the property maps to an RDN attribute of an LDAP class in the underlying store.
    Hashing Key Indicates that this property is used to distribute profile instances across multiple data source partitions. This property is read-only for non-partitioned data sources. To retrieve the profile, you must query on this key.
  • Custom attributes. Custom attributes on profile properties are placeholders for storing application-specific custom information. These attribute/value pairs must be of the type string. The maximum length of the attribute name or the value is 127 Unicode characters. For example, you can create a custom attribute that controls how a property is displayed on a Web site page.

    When you unpack a Solution Site, Commerce Server adds the custom attributes described in the following table.

    Attribute Description
    sAnonymousAccess Specifies user access to the property in the Customer Service. This attribute is not implemented in Commerce Server.
    sUserAccess Specifies registered user access to the property in the Customer Service. Set the attribute value to 0 to hide the property from registered users. Set the attribute value to 1 to allow registered users to view the property. Set the attribute value to 2 to allow registered users to view and edit the property.
    sDelegatedAdminAccess Specifies delegated administrator access to the property in the Customer Service and the Partner Service. Set the attribute value to 0 to hide the property from delegated administrators. Set the attribute value to 1 to allow delegated administrators to view the property. Set the attribute value to 2 to allow delegated administrators to view and edit the property.
    sSiteAdminAccess Specifies site developer access to the property in Business Desk. This attribute is not implemented in Commerce Server 2000.
    SearchOptions Specifies whether the profile property is searchable in the Customer Service and the Partner Service. Set the attribute value to ALL to make the property searchable in both regular and advanced search modes. Set the attribute value to ADVANCED to make the property searchable only in the advanced search mode. Set the attribute value to NONE to exclude the property from searches.
    ShowInList Specifies whether the property is displayed in the user search results list in the Partner Service. Set the attribute value to 1 to display the property. Set the attribute value to 0 to hide the property.
    sFeatureID Specifies the site scenarios for which the property is displayed in the Customer Service and the Partner Service. Set the attribute value to 2 to display the property only when the site supports the Delegated Admin options. Set the attribute value to 3 to display the property only when the site uses Active Directory. Set the attribute value to 0 to always display the property regardless of scenario.
    DWMembername Specifies the name of the Data Warehouse data member the property maps to.

The profile designer is available in both the Profiles resource and Business Desk. For information about using the Profile Designer module in Business Desk, see Business Desk Users.

See Also

Sample Profile Definitions

Adding a New Data Source

Adding a New Data Object

Adding a New Profile Definition

Adding Properties to Profile Definitions


All rights reserved.