MLS-C01 Data Engineering Practice Question
A data engineer is responsible for managing a data lake on Amazon S3. The data lake contains CSV files from various sources, totaling 10 TB. The engineer needs to make this data queryable using Amazon Athena. However, Athena queries are currently taking a long time and scanning large amounts of data. The engineer has noticed that the CSV files are not partitioned, and there are no indexes. The engineer wants to improve query performance and reduce costs. The data is accessed frequently for the last 30 days, but older data is rarely queried. The engineer also wants to minimize the amount of data scanned by Athena. What should the engineer do?
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
✓
Convert the CSV files to Parquet format and partition the data by date.
The best choice. Converting CSV to Parquet reduces data scanned due to columnar storage and compression. Partitioning by date allows Athena to skip older data that is rarely queried, further minimizing scan size and cost. Option A (JSON) does not improve performance significantly and still lacks partitioning. Option C is invalid because Athena does not support indexes. Option D (ORC) is columnar but without partitioning it performs worse than Parquet with partitioning, and views do not reduce scan size.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Convert the CSV files to JSON format and use Athena to query them.
Why it's wrong here
JSON is also text-based; it does not reduce scan size as effectively as columnar formats.
- ✓
Convert the CSV files to Parquet format and partition the data by date.
Why this is correct
Parquet is columnar and compressed; partitioning by date allows partition pruning, reducing scan size.
- ✗
Create indexes on the S3 objects using AWS Glue.
Why it's wrong here
Athena does not use indexes; it scans data directly.
- ✗
Convert the CSV files to ORC format and create a view in Athena.
Why it's wrong here
ORC is a columnar format, but without partitioning, queries still scan all data.
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 →
Same concept, more angles
3 more ways this is tested on MLS-C01
These questions test the same concept from different angles. Work through them to make sure you can recognise it however the exam phrases it.
Variation 1. Which TWO of the following are valid ways to reduce query costs in Amazon Athena? (Choose 2)
medium- A.Use UNLOAD to export query results to S3
- ✓ B.Partition the data in S3
- C.Increase the query timeout limit
- ✓ D.Use columnar storage formats like Parquet
- E.Enable encryption at rest on S3
Why B: (partitioning data) and Option D (using columnar formats like Parquet) are correct because both reduce the amount of data scanned by Athena queries, directly lowering costs. Option A (UNLOAD) exports results but does not reduce query costs. Option C (increasing query timeout) does not affect data scanned. Option E (encryption at rest) does not reduce costs.
Variation 2. A data engineer is designing a data lake on Amazon S3 that must support both batch and streaming analytics. The data comes in Parquet format and needs to be queryable by Amazon Athena. Which partitioning strategy will optimize query performance and reduce costs?
hard- ✓ A.Partition by date and hour for time-based queries
- B.Store data as CSV without partitioning for simplicity
- C.Partition by device_id for granular access
- D.Use a single partition for all data to simplify management
Why A: Partitioning by date and hour is optimal for time-series data in Parquet format queried by Athena because it leverages Hive-style partitioning to prune partitions during query execution, drastically reducing the amount of data scanned. This minimizes Athena's cost (which is based on data scanned) and improves query performance by limiting I/O to only the relevant partitions. Parquet's columnar storage further reduces scan volume when queries select only specific columns, making this combination highly efficient for both batch and streaming ingestion patterns.
Variation 3. A data engineering team is designing a data lake on Amazon S3. The data is ingested from multiple sources in JSON, CSV, and Parquet formats. The team needs to make the data available for analysis using Amazon Athena and Amazon Redshift Spectrum. The team wants to minimize data transformation costs and storage overhead. Which data storage approach should the team use?
hard- A.Load the data into Amazon Redshift cluster and then unload to S3 in Parquet
- B.Store the data in its original format in S3 and use Athena to query directly
- C.Store the data in its original format and use AWS Glue to convert to Parquet when queried
- ✓ D.Convert all data to Apache Parquet before storing in S3
Why D: Converting all data to Apache Parquet before storing in S3 minimizes storage overhead and improves query performance. Parquet is a columnar format that provides efficient compression and encoding schemes, reducing storage costs. It is natively supported by Amazon Athena and Redshift Spectrum, enabling fast analytics without on-the-fly conversion. Option B (storing in original format) increases storage costs and can degrade query performance, especially with JSON or CSV. Option C incurs transformation costs each time data is queried, negating any storage benefit. Option A adds unnecessary transformation steps and cluster costs. Therefore, upfront conversion to Parquet is the most cost-effective strategy for this use case.
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.