Skip to main content

Data objects

To process Cases, Pega Platform™ applications use data objects to collect related Case data. A data object is a template for describing an entity, such as a person or an item, by grouping a set of related fields.

For example, an application might contain an Account data object that you can use in two Case Types: one that allows the customer to transfer funds between bank accounts, and one that allows the customer to change the address that is associated with their account. The Account data object includes fields that describe an account, such as Account Number, Current Balance, and Next Statement Date. Referencing the Account data object avoids the need to define account-related fields for each Case Type. The following figure displays the relationship among the Transfer Funds and Change Address Case Types and the Account data object:

Account data object
 

You can use a data object as many times as needed in your application. In the preceding example, the Transfer Funds Case Type can use the Account data object to model both the source and target accounts for the transfer.

The collection of Case Types and data objects in your application holistically defines the Data Model for your application.

Structure

In addition to grouping data elements, data objects can group Views and other Rules related to the data object. For example, a HR application has a Candidate data object to collect information about a candidate for an open job requisition. The Candidate data object can include a calculation to combine a given name and surname into a full name for the candidate, such as John Smith.

You can extend the structure of a data object by referencing other data objects. Referenced data objects can be used either once or multiple times, depending on the need.

For example, the Candidate data object also needs to include fields for information such as a mailing address and employment history. The address and employment history can be configured as data objects referenced by the Candidate data object. The Address data object extends the Candidate data object with fields such as Street name, City, and Postal code, while the Employment history data object adds fields such as Start date, End date, Position, and Employer. The Address data object is used once to capture a single address, while the Employment history data object can be used more than once to create a list of prior employers for the candidate. The following figure displays the relationship among the New Candidate Case Type, Candidate data object, Address data object, and Employment history data object:

The New Candidate case type references a Candidate data object, which references two other data objects

Inheritance

You can create data objects to reuse assets from an existing data object through inheritance. For example, Person is a generic data object, or a parent data object, while Customer and Call Center Representative (CCR) are more specialized data objects. To denote the relationship between parent and child data objects, use the Parent-Child pattern, for example, Person-Customer and Person-CCR. All three data objects have common fields, including Name, Telephone, and Email. By creating the common fields in the Person data object, you can reuse the fields in the Customer and Call Center Representatives data objects. The fields Tax Identification Number and Membership Number apply to customers only, so you define them in the Customer data object. Because the field Employee ID applies to employees only, you define the field in the Call Center Representative data object. The following figure displays the relationship among the Person, Customer, and CCR data objects:

Person data object

Sourcing

You can source data objects locally from a Pega Platform system of record, or you can source data objects from an external system of record, such as an HR or inventory database your company already uses. Alternatively, data objects can obtain data that you or a Case participant enters or changes during application processing that are not associated with any system of record.

When you determine how to source a data object, consider the questions in the following image. The questions assume that you are new to Pega Platform and that you create an application from scratch.

In the following image, click + icons to learn about an example of each data object sourcing option:

Best practices

Whenever possible, use standard, commonly-used data objects that Pega Platform provides, such as Address-Postal and Address-Email. You can also add relevant data objects to your application.

If a data object only partially meets your needs, you can extend that data object. For example, if you want to create the Employee data object, you can extend the existing Person data object to create the Person-Employee data object.

If a suitable data object does not exist yet, create a new one. For example, if you want to add the Airport Codes data object, but you cannot use or extend an existing data object, create a new one in Pega Platform.

Tip: If you add a new data object to the Case workflow in App Studio, Pega Platform creates the data object as a draft object. Draft objects allow the business to identify how and when data is used in the Case Life Cycle. You can turn these data objects into permanent elements using the Data objects and integrations page.

Check your knowledge with the following interaction:


This Topic is available in the following Module:

If you are having problems with your training, please review the Pega Academy Support FAQs.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega Academy has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice