How to retrieve street addresses from BigQuery using Cloud DLP?

You have one BigQuery dataset which includes customers’ street addresses. You want to retrieve all occurrences of street addresses from the dataset. What should you do?

  1. Write a SQL query in BigQuery by using REGEXP_CONTAINS on all tables in your dataset to find rows where the word “street” appears.
  2. Create a deep inspection job on each table in your dataset with Cloud Data Loss Prevention and create an inspection template that includes the STREET_ADDRESS infoType. Source Reference Answer
  3. Create a discovery scan configuration on your organization with Cloud Data Loss Prevention and create an inspection template that includes the STREET_ADDRESS infoType.
  4. Create a de-identification job in Cloud Data Loss Prevention and use the masking transformation.

Community Votes

B
100%

100% of anonymous learners picked answer B. Votes are pick records left by other test-takers — they are not the verified answer.

Community Insight

This question tests the selection of Cloud DLP inspection methods for sensitive data discovery, with the common trap being choosing a brittle SQL regex pattern over DLP's built-in machine learning detectors.

To accurately identify and retrieve street addresses within a BigQuery dataset, Cloud Data Loss Prevention (DLP) deep inspection jobs with the STREET_ADDRESS infoType are the standard solution. The community consensus confirms this approach is superior to SQL regex for finding sensitive data patterns.

Choosing Option A is a common mistake because searching for the specific word 'street' fails to capture address variations like 'St', 'Avenue', or international formats.

Community Discussion (6 comments)

raaad 👍 6 Selected: B
  • Cloud Data Loss Prevention (Cloud DLP) provides powerful inspection capabilities for sensitive data, including predefined detectors for infoTypes such as STREET_ADDRESS. - By creating a deep inspection job for each table with the STREET_ADDRESS infoType, you can accurately identify and retrieve rows that contain street addresses.
josech 👍 2 Selected: B
https://cloud.google.com/sensitive-data-protection/docs/learn-about-your-data#inspection
JyoGCP 👍 1 Selected: B
Option B
AllenChen123 👍 1
Why not C? Discovery scan configuration can also help to identify risk/sensitivity fields.
Matt_108 👍 3 Selected: B
Option B - you want to retrieve ALL occurrences within the dataset
scaenruy 👍 2 Selected: B
B. Create a deep inspection job on each table in your dataset with Cloud Data Loss Prevention and create an inspection template that includes the STREET_ADDRESS infoType.

Comments & Corrections

No comments yet — spotted an error or have a note? Share it below.

Log in to comment, report an error, or add a note about this question.

Submitted for moderation before publishing. Keep it helpful and respectful.

Expert Analysis

Why the Answer Is Correct

Cloud Data Loss Prevention (Cloud DLP) is designed specifically to inspect, classify, and redact sensitive data. The STREET_ADDRESS infoType utilizes machine learning models to recognize address patterns rather than just specific keywords, ensuring high accuracy. By creating a deep inspection job on the specific tables, you ensure a thorough scan to retrieve all occurrences of the data.

Why the Other Options Are Wrong

Option A is incorrect because a SQL query using REGEXP_CONTAINS for the word 'street' is too rigid and will miss valid addresses that use abbreviations (e.g., 'St') or different street types (e.g., 'Road', 'Ave'). Option C refers to a discovery scan on the organization, which is typically used for broader risk assessment and metadata scanning rather than retrieving data from a specific dataset. Option D involves de-identification (masking), which is the opposite of retrieving the data.

Community Comment Notes

Community comments strongly support Option B, highlighting that Cloud DLP provides 'powerful inspection capabilities' and 'predefined detectors' necessary for the task. Users emphasized that the requirement to retrieve 'ALL occurrences' necessitates the robust pattern matching of DLP. One comment clarified why Option C is incorrect by distinguishing discovery scans from deep inspection jobs.

Official Reference

Exam Strategy

When questions ask to identify or retrieve sensitive data patterns like PII, immediately look for Cloud DLP options involving inspection jobs and infoTypes. Avoid SQL-based solutions for pattern matching unless the scenario explicitly restricts you to SQL or the pattern is trivial.

Related Analysis

← Back to PDE Study Guide