Skip to main content
Version: Next

Data Quality Configuration

This page explains how and where to configure data quality scores for Data Objects.

Add a data quality component to a Data Object class definition through the context menu Add Data Component > Other > Data Quality.

Data Quality Data ComponentData Quality Data ComponentData Quality Data Component

Show in Tree

Show In TreeShow In TreeShow In Tree

Controls whether the data quality score appears next to the object in the Data Object tree. A data quality component added in Pimcore Studio starts with the toggle off, so enable it explicitly.

Precondition

Use the Precondition field to narrow the scope of Data Objects for which the data quality score is shown, for example to exclude unpublished Data Objects, or to calculate the score only for objects in a target folder.

If the precondition is not met, the data quality summary is hidden. The precondition accepts any valid Symfony Expression.

tip

The Data Object is passed to the expression. Use object to build the expression.

The following precondition limits score calculation to published Data Objects:

//precondition example
object.getPublished() == true

Rule Definitions

Configure the rules used to compute the data quality score by selecting one or more rule definitions. Each selected rule definition is a constraint of one of the following types:

Rule DefinitionRule DefinitionRule Definition

info

Weight determines the impact of a rule definition on the data quality score: a higher weight gives the rule more influence over the resulting score. Every new rule definition starts with the same default weight.

Object Validation Check

Checks whether all mandatory fields are filled and all validation rules are respected (for example min/max values for numeric fields, or regular expressions for input fields).

Object Validation CheckObject Validation CheckObject Validation Check

When the check fails, it shows auto-generated suggestions to improve data quality in the object editor's Data Quality Details tab.

Checks whether manually defined recommended fields are filled. Missing fields reduce the data quality score.

Recommended Fields CheckRecommended Fields CheckRecommended Fields Check

When the check fails, it shows auto-generated suggestions to improve data quality in the object editor's Data Quality Details tab.

Symfony Expression Check

Evaluates a Symfony Expression against the Data Object. Access the Data Object with object (for example object.getField1()).

Symfony Expression CheckSymfony Expression CheckSymfony Expression Check

Add a suggestion that appears in the object editor's Data Quality Details tab when the expression does not match.

info

Set the suggestions' translations in the Translations section of the Pimcore Studio main navigation, under the dataQualityManagement domain. Saving the class definition registers every key listed in a rule's fieldsToTranslate in that domain, so the entries are already there waiting for their translations.

caution

The text a getter returns can differ from the text shown in the Data Object editor. For the Country field, for example, the editor displays the full country name (such as "Austria"), but the getter returns only the country code (such as "AT"). Match the Symfony expression to the getter's format, not the displayed text (use "AT", not "Austria", for a Country check).