DBT vs. Data Engineers: A Love-Hate Saga!

sudo_pradip

Pradip Sodha

Posted on October 3, 2024

DBT vs. Data Engineers: A Love-Hate Saga!

No doubt, DBT (Data Build Tool) has introduced a whole new approach to writing transformations. Or should I say, the “correct” way to write them? But if you’ve been a data engineer for 5 to 10 years, DBT might feel...strange. Maybe even unnecessary or over-complicated. You’ve likely found comfort in the traditional ways of doing things—Databricks notebooks, Azure Data Flows, stored procedures, etc.—giving you more control over your work. Let’s explore why, from a data engineer’s perspective, DBT can feel like an alien language and what makes it a tough beast to tame.


1. Only SELECT Statements? Say What?!

DE: If I open any DBT model file, all I see are SELECT statements. What if I want a good ol’ MERGE or INSERT statement? Oh wait, I have to check DBT docs for that? Really? I’ve mastered MERGE over the past decade, and now I need to look up docs like a newbie? And what if there’s a new DML feature? I have to wait for DBT to support it? Feels like I’m shackled! And don’t get me started on conditional updates or deletes—where do I even go to beg for those?

DBT: I get it. You’re right, but let’s flip the script. You don’t need to worry about DDL (create, alter) or DML (insert, merge) anymore. Focus on your transformations; I’ll handle the nitty-gritty! By abstracting these tedious commands, you can scale easier and faster. And hey, if DBT doesn’t support a feature yet, get yourself a solid software engineer. Seriously, they’re the magic fix for everything. What are you waiting for?

Pro Tip: DBT’s secret sauce is a good software engineer. Get one who’s also a data engineer, and you’ll be flying in no time. Heaven awaits, trust me!


2. Jinja is... Well, Something

DE: What is this Jinja stuff? Honestly, it’s harder to read and write than the worst SQL I’ve ever seen. Sometimes, I dream of Jinja syntax haunting me like floating code fragments.

DBT: Oof, I hear you. We’ve all had second thoughts about using Jinja, and managing it is a struggle. But hey, it’s a powerful templating engine! With its if-else and for-loops, you can write dynamic SQL that will take your transformations to the next level. Hang in there, my friend, the power will reveal itself!


3. Documentation Drama!

DE: Sure, documentation is great, but now my team relies on docs instead of SQL. The doc could say the Earth is flat, and they’d believe it, even if the query says it’s round! The problem? Docs are rarely up-to-date. And when you’ve got deadlines, there’s no time to update them. Worst of all, if there’s a mistake in the doc, who’s going to catch it? SQL errors get flagged, but docs? Good luck.

DBT: Whoa, slow down. Docs are crucial! They bring stakeholders, downstream, and upstream users together. No more wading through murky SQL—everyone can just read the doc in a pretty UI! Sure, if the doc is wrong, that’s a problem, but you can automate doc checks using tools like dbt checkpoint. And let’s be honest, if your doc says the Earth is flat, that’s on you.


4. Dev Setup & Deployment: The Struggle is Real

DE: Setting up a DBT project is an achievement in itself. Managing versioning, syntax, spacing, and linting across devs is a nightmare. If there’s an error, I’m diving through a swamp of logs. Plus, I have to set up a virtual environment, learn Docker, and deploy to AWS ECS. Seriously?

DBT: I feel your pain, but have you heard of DBT Cloud? It solves all of these issues! Just give me your money, and I’ll make everything easier. Oh, and I’ve teamed up with Databricks—so now you can run DBT tasks in Databricks Workflows! It’s in the premium workspace though, so you’ll need to cough up a bit more.


5. DBT for Small Projects? Worth It?

DE: Why are even small projects pushing to use DBT? It’s expensive! Not just the learning curve, but hiring a software engineer who’s constantly complaining about everything costs a fortune. Seriously, the guy is impossible to work with!

DBT: Listen, even if your project is small, one day you’ll be a unicorn. You need tools that can handle the pressure when you scale. But, if you want to keep costs down, you could try a minimalist approach. Skip the fancy Jinja and stick to organized SQL files. Slowly adopt more DBT features as you grow. It’s like evolving from the Stone Age to the modern era—DBT is the future!


Conclusion:

DBT is a powerful tool, but it can be a bit of a pain for data engineers used to more traditional methods. It demands a lot—sometimes too much. But with the right mindset (and maybe a software engineer who knows what they’re doing), DBT can help you scale and succeed. Just... be ready for a few headaches along the way!

💖 💪 🙅 🚩
sudo_pradip
Pradip Sodha

Posted on October 3, 2024

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related