Courseiva
Back to Google Professional Cloud Database Engineer questions

Scenario-based practice

Refer to the Exhibit Practice Questions

Practise Google Professional Cloud Database Engineer practice questions — original exam-style scenarios covering every exam domain, with detailed explanations, wrong-answer analysis, and common exam traps.

12
scenario questions
PCDE
exam code
Google Cloud
vendor

Scenario guide

How to approach refer to the exhibit practice questions

Practise exhibit-style questions that ask you to read a topology, table, command output or diagram before choosing the best answer.

Quick answer

Exhibit-style questions test whether you can read a topology, command output, diagram or table before choosing the best answer.

How to extract the relevant detail from an exhibit.

How topology, command output or routing information affects the answer.

How to avoid answering from memory before reading the evidence.

How to map the exhibit back to the exam objective.

Related practice questions

Related PCDE topic practice pages

Scenario questions usually connect to one or more exam topics. Use these links to review the underlying concepts behind the scenario.

Practice set

Practice scenarios

Question 1hardmultiple choice
Full question →

Refer to the exhibit. This DDL is used to create a table in Cloud Spanner. The table will be used for storing user data with high write throughput. What is one performance issue with this table design?

Exhibit

CREATE TABLE Users (
  UserId INT64 NOT NULL,
  Name STRING(MAX),
) PRIMARY KEY (UserId);
Question 2mediummultiple choice
Full question →

The exhibit shows query metadata for a query that scans 10 GB. Given the table is 100 GB and partitioned by hire_date, why did the query scan 10 GB and not less?

Exhibit

Refer to the exhibit.

```sql
-- BigQuery query results metadata
Query statement: SELECT department, COUNT(*) as cnt
FROM `project.dataset.employees`
WHERE hire_date >= '2023-01-01'
GROUP BY department
ORDER BY cnt DESC

Query plan:
- Stage 1: Input (scan) - 10 GB processed
- Stage 2: Aggregate - 5 GB processed
- Stage 3: Sort - 0 GB processed

Table details:
- Table size: 100 GB
- Partitioned by: hire_date (daily)
- Clustered by: department
```
Question 3mediummultiple choice
Full question →

Refer to the exhibit. You receive an alert from this policy for a Cloud Spanner instance. Which action should you take first?

Exhibit

Refer to the exhibit.

```
# Cloud Monitoring alert policy configuration
condition:
  conditionThreshold:
    filter: metric.type="spanner.googleapis.com/instance/node_cpu_utilization"
           resource.type="spanner_instance"
           resource.label.instance_id="my-spanner-instance"
    aggregations:
    - alignmentPeriod: 60s
      perSeriesAligner: ALIGN_MEAN
    - crossSeriesReducer: REDUCE_MEAN
    duration: 300s
    comparison: COMPARISON_GT
    thresholdValue: 0.7
```
Question 4easymultiple choice
Full question →

Refer to the exhibit. A company wants to perform point-in-time recovery (PITR) for their Cloud SQL MySQL instance. Is PITR enabled?

Exhibit

gcloud sql instances describe my-instance --format='json' | jq '.settings.backupConfiguration'
{
  "binaryLogEnabled": true,
  "enabled": true,
  "startTime": "03:00",
  "transactionLogRetentionDays": 7
}
Question 5mediummultiple choice
Full question →

A company notices that their Cloud SQL for PostgreSQL instance, as shown in the exhibit, frequently runs out of storage, causing downtime. They have set up automated backups with point-in-time recovery. What is the most likely cause of the storage issue?

Exhibit

Refer to the exhibit.

gcloud sql instances describe my-instance
...
databaseVersion: POSTGRES_13
settings:
  activationPolicy: ALWAYS
  availabilityType: ZONAL
  backupConfiguration:
    enabled: true
    pointInTimeRecoveryEnabled: true
    startTime: '03:00'
    transactionLogRetentionDays: '7'
  dataDiskSizeGb: '100'
  dataDiskType: PD_SSD
  tier: db-custom-4-15360
...
Question 6hardmultiple choice
Full question →

A team is reviewing IAM permissions on a Cloud Storage bucket. The exhibit shows the bucket's IAM policy. A developer is using the service account sa-1 and reports that they cannot delete objects in the bucket. What is the likely reason?

Exhibit

Refer to the exhibit.

{
  "bindings": [
    {
      "role": "roles/storage.objectViewer",
      "members": [
        "serviceAccount:sa-1@project.iam.gserviceaccount.com",
        "user:admin@example.com"
      ]
    },
    {
      "role": "roles/storage.objectAdmin",
      "members": [
        "serviceAccount:sa-2@project.iam.gserviceaccount.com"
      ]
    }
  ],
  "etag": "BwXQ=="
}
Question 7hardmultiple choice
Full question →

Refer to the exhibit. You restored a Spanner database from a backup and are checking the status of the optimize operation. The operation has been running for 15 minutes and is 45% complete. The database is already accessible but queries on it are slower than expected. What should you do?

Exhibit

gcloud spanner operations describe projects/my-project/instances/test-instance/databases/test-db/operations/_auto_12345

--output:
name: projects/my-project/instances/test-instance/databases/test-db/operations/_auto_12345
metadata:
  '@type': type.googleapis.com/google.spanner.admin.database.v1.OptimizeRestoredDatabaseMetadata
  name: projects/my-project/instances/test-instance/databases/test-db
  progress:
    progress_percent: 45
  start_time: '2023-10-01T10:00:00Z'
  end_time: '2023-10-01T10:15:00Z'
done: false
error: null
Question 8mediummultiple choice
Full question →

Refer to the exhibit. The query joins two large tables and aggregates results. Which optimization would most likely reduce the high shuffle bytes in Stage 3?

Exhibit

Refer to the exhibit. In a BigQuery query plan, you see the following stage statistics:

Stage 2: WRITE, 1.2 GB shuffled, 45 seconds
Stage 3: SHUFFLE, 2.5 GB shuffled, 80 seconds
Stage 4: AGGREGATE, 0.5 GB input, 15 seconds
Question 9hardmultiple choice
Full question →

Refer to the exhibit. A data engineer created a materialized view on a table that receives streaming inserts. When they query the materialized view, they get this error. What is the most likely cause?

Exhibit

Refer to the exhibit.
bigquery error: Query failed: Cannot query a materialized view that references a table with streaming buffer data.
Question 10hardmulti select
Full question →

Refer to the exhibit. A company has a Cloud Spanner instance with the backup configuration shown. They need to improve disaster recovery. Which THREE strategies should they implement?

Exhibit

Refer to the exhibit.

```json
[
  {
    "name": "projects/my-project/instances/test-instance/backups/backup-1",
    "createTime": "2024-01-15T10:00:00Z",
    "expireTime": "2024-01-22T10:00:00Z",
    "versionTime": "2024-01-15T10:00:00Z",
    "database": "projects/my-project/instances/test-instance/databases/mydb",
    "state": "READY",
    "referenceBackup": null,
    "encryptionInfo": {
      "encryptionType": "GOOGLE_DEFAULT_ENCRYPTION"
    }
  }
]
```
Question 11easymultiple choice
Full question →

Refer to the exhibit. You are analyzing a slow query in Cloud SQL for PostgreSQL. The execution plan shows a sequential scan. Which index should you create to most effectively improve query performance?

Network Topology
+Refer to the exhibit.```Database: mydbTable: orderscolumn | type | sizetotal | float| 8 bytesIndexes:"orders_pkey" PRIMARY KEY, btree (id)"idx_orders_user_id" btree (user_id)Query:Execution Plan:
Question 12easymultiple choice
Full question →

Refer to the exhibit. The BI team creates a view to summarize sales. When they query the view with an additional WHERE clause on region, they notice that the underlying query still processes the same amount of data regardless of the filter. What is the most likely reason?

Exhibit

Refer to the exhibit.

CREATE VIEW `myproject.mydataset.sales_summary` AS
SELECT region, SUM(sales) AS total_sales
FROM `myproject.mydataset.sales`
WHERE date >= '2023-01-01'
GROUP BY region;

These PCDE practice questions are part of Courseiva's free Google Cloud certification practice question bank. Courseiva provides original exam-style PCDE questions with detailed explanations, topic-based practice, mock exams, readiness tracking, and study analytics.