
Data Records
Data records
Applications often require access to data that is used to process cases but is not directly part of the application. Data records provide values for the fields associated with a particular data type and can be stored outside the case. As a result, you can widely reuse and reference data records.
Note: For more information about data types, refer to the Data types help article.
Data records define permissible values for data fields. Limiting the input values to valid options reduces errors and allows for automation.
For example, you have an airport code drop-down list. There is a data type for Airports. Each airport includes a value for the airport code, city, and country. The values in the Airport data type do not vary among case types. In this example, only the user-selected airport code and location information is added to and persisted with the case.
Note: After adding data records to a data type, you can reference the data type in a form. By default, the data records display in a selectable drop-down list. When an option is selected, the associated values can be displayed in the form, as shown in the following image.
Data records and data types
In Pega Platform™, data types represent key business entities, such as customers. Data types contain all the fields necessary to describe an object. For example, an identifier, name, address, and date of account creation describe a customer.
Generally, a change to data record values does not need an associated change in the business process to support the change. Whereas, a change in the data type fields represents a change in the business processes. For example, adding a new customer is part of the standard business process. Adding a new customer level — for example, platinum — results in a modification to the business processes to manage platinum customers.
Ways to use data records
In a Pega Platform application, there are several ways to create and use data records to reference data.
Configure local data storage
A local data storage lets you store data records for a data type, without having to create or maintain database tables. Data records stored using a local system of record can be packaged and distributed as part of an application.
Each data type has a property that serves as the unique record key. After you create the local data source, you can add records to the data source.
For example, in the Office data type, you can add records for each office location. The ID property is the unique key that identifies each office.
Connect to an external database
You can retrieve data from external database storage by using connectors. For example, a purchase application needs access to currency exchange rates. Exchange rate information is stored in an external database table.
Note: For more information about Connectors, refer to the Connector help article.