PCDE Plan and manage database infrastructure Practice Question
A financial services company uses Cloud Spanner for transaction processing. They need to ensure zero downtime during a schema change that adds a new column with a default value to a large table. Which approach should the Database Engineer take?
⚠ Common exam trap
Many exam-takers assume schema changes on large databases always require a maintenance window or a workaround like dual-write patterns, but Spanner's distributed architecture is specifically designed to handle schema changes online without downtime.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
Use ALTER TABLE to add the column; Spanner handles schema changes online.
Cloud Spanner supports online schema changes, including adding columns with default values, without requiring a maintenance window or causing downtime. Spanner applies schema updates asynchronously across all nodes while the database remains fully available for reads and writes, making it the ideal approach for zero-downtime requirements.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Create a new table with the new column, then use a fan-out pattern to write to both tables until the old table is deprecated.
Why it's wrong here
This approach is overengineered for a simple column addition.
- ✗
Use an ALTER TABLE statement during a maintenance window.
Why it's wrong here
Spanner does not require a maintenance window; schema changes are online.
- ✗
Drop the table and recreate it with the new schema.
Why it's wrong here
Dropping a table causes downtime and data loss.
- ✓
Use ALTER TABLE to add the column; Spanner handles schema changes online.
Why this is correct
Spanner schema changes are online and do not cause downtime.
Go deeper
Related to this question
About these practice questions
One of 1,446 original PCDE practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This PCDE practice question is part of Courseiva's free Google Cloud certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the PCDE exam.