PEGACPLSA23V1 practice question 3 of 15

[Data Modeling] As an LSA developing a Pega application for an online grocery store, you are tasked with enabling customers to navigate through…

Full set: 60 questions
[Data Modeling] As an LSA developing a Pega application for an online grocery store, you are tasked with enabling customers to navigate through various categories such as "Dairy," "Confectionery," "Frozen Food," and "Soft Drinks." Each category contains at least 10 sub-categories, with the workflow varying depending on the selected sub-category. What is the best method of populating the categories and sub-categories and retrieving the related information from the grocery store's database?
Answer options
A: Implement a data page that accepts either a Category or Sub-category as a parameter. Based on the parameter type, the required information is retrieved and displayed in the subsequent layouts.
B: Implement a data page for Sub-categories. Load Categories by default upon startup. Populate Sub- categories after a Category is selected, using a Sub-category data page that takes the Category as a parameter.
C: Implement data pages for Categories and Sub-categories. Populate Sub-categories after a Category is selected, using a Sub-category data page that takes the Category as a parameter. Correct answer
D: Implement a data page that takes the Sub-category as a parameter. Based on the Sub-category type, the necessary information is retrieved and shown in the subsequentpf layouts.
Correct Answer:
C. Implement data pages for Categories and Sub-categories. Populate Sub-categories after a Category is selected, using a Sub-category data page that takes the Category as a parameter.
Explanation

This scenario describes a classic cascading or dependent data relationship. The best practice in Pega is to use separate, dedicated data pages for each distinct data entity. A list-structure data page should be created to populate the top-level Categories. A second, parameterized list-structure data page should be created for Sub-categories. This Sub-category data page accepts the selected Category ID as a parameter to filter and retrieve only the relevant sub-categories from the database. This approach is modular, reusable, and aligns with Pega's data virtualization principles for optimal performance and maintainability.

Why Incorrect

A: Using a single, complex data page for both entities violates the single responsibility principle, making it less reusable, harder to maintain, and less performant than two dedicated data pages. B: This option is incomplete as it fails to specify a data page for loading the initial Category list, which is a critical first step and a Pega best practice. D: This option only addresses retrieving data after a Sub-category is selected. It completely ignores the primary requirement of how to populate the Category and Sub-category selection lists.

References

1. Pega Documentation

"Configuring a cascading control": This document explicitly outlines the correct pattern. It states

"To configure a cascading control

you create two controls and source them with two separate data pages. The first data page retrieves a list of values for the first control. The second data page is parameterized to retrieve a filtered list of values for the second control based on the value of the first control." This directly supports option C.

Source: Pega Community / Pega Platform 8.8 Documentation

"Configuring a cascading control".

2. Pega Documentation

"Creating a data page": The documentation on creating data pages emphasizes their role in separating data retrieval logic from the UI. It details the use of parameters to make data pages context-aware

which is the core mechanism for the Sub-category data page.

Source: Pega Community / Pega Platform 8.8 Documentation

"Creating a data page"

Section: "Data page parameters".

3. Pega Academy

Lead System Architect (LSA) Courseware

"Data Modeling" Module: The LSA curriculum stresses the importance of creating a clean

logical

and reusable data model. The principle of creating distinct data pages for distinct business objects (like Category and Sub-category) is a fundamental concept for building scalable and maintainable applications.

Source: Pega Academy

Lead System Architect 8.8

"Data and Integration" Mission

"Data Pages" Module.

Scroll to Top