←back to thread

61 points captaintobs | 2 comments | | HN request time: 0s | source
Show context
whinvik ◴[] No.41853594[source]
Can someone who understands it explain what dbt is and how it is used. I hear a lot about it but I just haven't figured out what it is useful for.
replies(4): >>41853616 #>>41853867 #>>41853925 #>>41855656 #
1. gkapur ◴[] No.41853925[source]
Basically people are constantly calculating metrics based on existing tables. Think something as simple as a moving average or the sum of two separate columns in a table. Once upon a time you would set up a cronjob and populate these every day as a SQL query in some python or Perl script.

Dbt introduced a language for managing these “metrics” at scale including the ability to use variables and more complex templates (Jinja.)

Then you do dbt run (https://docs.getdbt.com/reference/commands/run) and kapow the metric is populated in your database.

More broadly dbt did two other things: 1. It pushed the paradigm from ETL to ELT (so stick all the data in your warehouse and then transform it rather than transform it at extraction time.) 2. It created the concept of an “analytics engineer” (previously know as guy who knows SQL or business analyst.)

replies(1): >>41854395 #
2. ◴[] No.41854395[source]