Courseiva

PCDE Practice Question: Manage a solution that can span multiple database technologies

A financial services company uses Cloud Spanner for a globally distributed application. They need to add a new column to an existing table that contains billions of rows. The change must not cause any downtime or performance degradation. How should the engineer implement this schema change?

⚠ Common exam trap

The common misconception is that schema changes on large distributed databases require manual backfill or table recreation, but Cloud Spanner's online DDL handles this transparently 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 ADD COLUMN; Spanner applies the change online without downtime.

Cloud Spanner supports online schema changes via the `ALTER TABLE ADD COLUMN` statement, which applies the change asynchronously without locking the table or causing downtime. Spanner uses a multi-phase approach to add columns, allowing reads and writes to continue uninterrupted while the schema change propagates across all nodes and regions.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • Use ALTER TABLE ADD COLUMN; Spanner applies the change online without downtime.

    Why this is correct

    Correct. Spanner's DDL is online and non-blocking.

  • Export the table, modify the schema in a temporary table, and import it back.

    Why it's wrong here

    This is a legacy approach that involves significant downtime and complexity.

  • Use CREATE INDEX to add the column as an index.

    Why it's wrong here

    An index is not a column; this does not add a column to the table.

  • Create a new table with the additional column, backfill data from the old table, then rename the tables.

    Why it's wrong here

    This manual approach is unnecessary and risky. Spanner supports online ALTER TABLE.

About these practice questions

This PCDE question is part of Courseiva's 1,446-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

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.