PDE Ingesting and Processing the Data Practice Question
A data engineer needs to load a 10 GB CSV file from GCS into BigQuery. The file contains some malformed rows that should be skipped. Which approach is most efficient?
⚠ Common exam trap
Google often tests the misconception that complex ETL pipelines (Spark, Dataflow) are always required for data cleaning, when in fact BigQuery's native load options like `--max_bad_records` can handle common malformed row scenarios directly and more efficiently.
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 the bq command-line tool with the --max_bad_records flag
The `bq` command-line tool's `--max_bad_records` flag allows BigQuery's native CSV loader to skip malformed rows up to a specified limit during a load job. This is the most efficient approach for a one-time batch load of a 10 GB file, as it avoids the overhead of spinning up separate processing clusters (Dataproc, Dataflow) or streaming each row individually, leveraging BigQuery's optimized ingestion pipeline.
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 Dataproc to run a Spark job that cleans the data and writes to BigQuery
Why it's wrong here
Unnecessary complexity for a single file.
- ✗
Use the Storage Write API to stream each row, skipping bad ones in code
Why it's wrong here
Streaming is for real-time; batch load is better for a 10 GB file.
- ✗
Use a Dataflow pipeline to read CSV, filter bad rows, and write to BigQuery
Why it's wrong here
Overkill for a simple load; inefficient for a single file.
- ✓
Use the bq command-line tool with the --max_bad_records flag
Why this is correct
bq load with --max_bad_records skips malformed rows efficiently.
Go deeper
Related to this question
About these practice questions
This PDE question is part of Courseiva's 747-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 →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This PDE 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 PDE exam.