Skip to content
tezvyn:

Data lake versus data warehouse

Source: interviewEasyHow cards are made

Summary

storage architecture fundamentals.

Key points

lakes store raw, schema-on-read data of any type cheaply; warehouses store curated, schema-on-write structured data for fast SQL; choose a lake for varied raw data and ML.

What's really being asked

This checks foundational understanding of two storage paradigms and the judgment to pick the right one for a workload.

The full answer

A data warehouse stores structured, cleaned, and modeled data using schema-on-write, meaning the schema is defined and enforced before loading, which makes SQL and business intelligence queries fast and consistent but requires upfront modeling and tends to cost more per gigabyte. A data lake stores raw data of any shape, structured tables, JSON, images, logs, on inexpensive object storage using schema-on-read, where structure is applied at query time, giving flexibility for diverse and evolving sources at very low storage cost. The tradeoff is that lakes need governance and good cataloging or they degrade into unusable data swamps, and ad hoc query performance can be worse without optimization. You choose a lake when sources are varied or unstructured, volumes are huge, you want to ingest first and decide schema later, or you are feeding machine learning and exploratory analytics. You choose a warehouse when consumers need fast, governed SQL over well-defined business metrics. Many teams combine both in a lakehouse.

The mistakes people make

Saying they are interchangeable. Claiming a lake replaces a warehouse entirely, ignoring BI performance needs. Describing the difference only as cheap versus expensive without mentioning schema-on-read versus schema-on-write. Forgetting governance, which is what separates a usable lake from a swamp.

What usually comes next

What is a lakehouse. How do you prevent a data swamp. How does query performance differ.

A concrete example

A startup ingests clickstream JSON, product images, and order tables into an S3 data lake to keep raw data cheaply and train ML models, then loads curated daily sales aggregates into a warehouse so analysts get fast, reliable dashboards.

Interview question

When is a data lake the better choice over a traditional data warehouse?

  • a.When data volume is tiny and fully structured
  • b.When sources are diverse or unstructured and you want schema-on-read flexibilityCorrect
  • c.When you need the fastest governed SQL over fixed business metrics
  • d.When you want to enforce a strict schema before any data lands
Why?

Lakes excel at storing diverse, raw, large-volume data cheaply with schema applied at read time. Fast governed SQL over fixed metrics and strict schema-on-write are exactly what a warehouse is built for.

Just read this? Test yourself on what you have been reading.

Read the original → cloud.google.com

You just looked this up. Could you explain it out loud?

That is the part interviews actually test. Tezvyn takes questions like this one and gives you what the interviewer is really checking, the answer that lands, and the mistake that ends the conversation, in the four minutes before your next meeting.

The iPhone app is on the way

We are building it. Until it lands, nothing here is held back from you: every interview card, your saved cards, streaks and the job board all work in Safari, plus hundreds of free practice quizzes of thirty questions each. Sign in and it all carries over to the app the day it arrives.

Want it as an icon? Tap Share at the bottom of Safari, then Add to Home Screen. It opens full screen and the cards you have read stay available offline.

Get it on Google PlayiPhone app coming soon

We are hiring for this. Open roles that interview on cloud — each one lists the topics its interview covers.

See open roles