MLS-C01 Data Engineering Practice Question
A data engineering team needs to build a data lake on Amazon S3 that will be queried by Amazon Athena and Amazon Redshift Spectrum. The data will be ingested from multiple sources in various formats (CSV, JSON, Parquet). Which partitioning strategy will provide the best query performance for date-range queries?
⚠ Common exam trap
Candidates often think a flat daily partition is simpler and sufficient, but they overlook that hierarchical partitioning (year/month/day) provides better partition pruning for range queries spanning months or years, which is a key optimization for Athena and Redshift Spectrum's cost and performance model.
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
✓
Partition by year, month, and day in a hierarchical structure.
Partitioning by year, month, and day in a hierarchical structure minimizes the amount of data scanned by Amazon Athena and Redshift Spectrum for date-range queries. Athena and Redshift Spectrum both charge per byte scanned, so reducing the scan size directly improves performance and reduces cost. A hierarchical partition structure (e.g., s3://bucket/year=2023/month=11/day=01/) allows the query engine to prune partitions at each level, efficiently skipping irrelevant directories for queries like WHERE date BETWEEN '2023-11-01' AND '2023-11-30'.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Partition by date with one partition per day in a flat structure.
Why it's wrong here
For large datasets, daily partitions can be too many; hierarchical partitioning is better.
- ✗
Do not partition; let Athena scan the entire dataset.
Why it's wrong here
No partitioning leads to full scans, increasing cost and latency.
- ✓
Partition by year, month, and day in a hierarchical structure.
Why this is correct
Hierarchical date partitioning enables partition pruning for date-range queries.
- ✗
Partition by source system first, then by date.
Why it's wrong here
If queries often filter by date across sources, this partitioning may not be optimal.
Quick reference
AWS S3 Storage Class Comparison
| Storage Class | Min Duration | Retrieval | Use Case |
|---|---|---|---|
| S3 Standard | None | Immediate | Frequently accessed data |
| S3 Standard-IA | 30 days | Immediate | Infrequent access, rapid retrieval |
| S3 One Zone-IA | 30 days | Immediate | Non-critical infrequent data |
| S3 Intelligent-Tiering | None | Immediate–hours | Unknown or changing access patterns |
| S3 Glacier Instant | 90 days | Milliseconds | Archive with instant retrieval |
| S3 Glacier Flexible | 90 days | Minutes–hours | Archive, flexible retrieval |
| S3 Glacier Deep Archive | 180 days | Hours | Long-term compliance archive |
Go deeper
Related to this question
About these practice questions
This MLS-C01 question is part of Courseiva's 1,672-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 MLS-C01 practice question is part of Courseiva's free Amazon Web Services 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 MLS-C01 exam.