docs/en/integrations/knowledge-catalog/tools/knowledge-catalog-get-data-quality-results.md
A dataplex-get-data-quality-results tool retrieves the results of a completed Data Quality scan.
WARNING: You must verify the execution run has succeeded (via dataplex-get-run-status) before calling this tool, otherwise the results will be empty.
CRITICAL: Access the results via the nested public fields dataQualityResult inside the returned DataScan.
Note that the failingRowsQuery field inside the rules result is extremely useful for retrieving failed rows.
{{< compatible-sources >}}
Knowledge Catalog uses Identity and Access Management (IAM) to control user and group access to Knowledge Catalog resources. Toolbox will use your Application Default Credentials (ADC) to authorize and authenticate when interacting with [Knowledge Catalog][dataplex-docs].
In addition to setting the ADC for your server, you need to ensure the IAM identity has been given the correct IAM permissions for the tasks you intend to perform. See Knowledge Catalog IAM permissions and Knowledge Catalog IAM roles for more information on applying IAM permissions and roles to an identity.
The dataplex-get-data-quality-results tool accepts the following parameters:
| field | type | required | description |
|---|---|---|---|
| scanId | string | true | The unique ID of the Dataplex quality scan (e.g. nq-dq-12345). |
| location | string | true | The Google Cloud region where the scan was created (e.g. us-central1). |
kind: tool
name: get_data_quality_results
type: dataplex-get-data-quality-results
source: my-dataplex-source
description: Fetch results of a completed data quality scan.
| field | type | required | description |
|---|---|---|---|
| type | string | true | Must be "dataplex-get-data-quality-results". |
| source | string | true | Name of the source the tool should execute on. |
| description | string | true | Description of the tool that is passed to the LLM. |